Skip to content

Add rubocop-minitest#920

Open
amomchilov wants to merge 6 commits into
mainfrom
Alex/rubocop-minitest
Open

Add rubocop-minitest#920
amomchilov wants to merge 6 commits into
mainfrom
Alex/rubocop-minitest

Conversation

@amomchilov
Copy link
Copy Markdown
Contributor

And turn on Minitest/AssertPredicate, matching Ruby LSP

@amomchilov amomchilov requested a review from a team as a code owner May 13, 2026 14:51
@amomchilov amomchilov enabled auto-merge May 13, 2026 15:00
Comment thread test/spoom/context/git_test.rb Outdated

sha = T.must(context.git_last_commit(short_sha: false)).sha
assert(sha.size == 40)
assert_equal(sha.size, 40)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The auto-correct put the arguments in the wrong order. Convention is assert_equal(expected, actual), and the line right below follows it correctly.

Suggested change
assert_equal(sha.size, 40)
assert_equal(40, sha.size)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah Minitest/LiteralAsActualArgument is not enabled by default yet (it's pending). I enabled it and auto-corrected this.

@amomchilov amomchilov force-pushed the Alex/rubocop-minitest branch from a0ab66c to ffb56e1 Compare May 14, 2026 17:04
@amomchilov amomchilov requested a review from Morriar May 14, 2026 17:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants