-
-
Notifications
You must be signed in to change notification settings - Fork 10.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
rubocop: Enable RSpec/ContextWording cop & fix offenses #10658
rubocop: Enable RSpec/ContextWording cop & fix offenses #10658
Conversation
- For some of these I changed `context` to `describe` as it fit better rather than contriving a "when", "with" or "without", or massively restructuring the tests.
- I couldn't figure out a way to start these with "when", "with" or "without" given where these are in cop descriptions. Three ignored things out of 150 problems is a good ratio though.
Review period will end on 2021-02-22 at 23:33:16 UTC. |
Co-authored-by: Nanda H. Krishna <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
I pointed out a few places where I think the wording is sub-optimal (just due to the constraints of the cop rules). I don't think any of them are unclear so I wouldn't bother changing unless anyone has a good idea for how to do it. I couldn't think of any, so I definitely won't complain 😅
@Rylan12 Thanks, how does the latest commit look? |
- We could have added "to" to the `RSpec/ContextWording` list of valid `context` prefixes, but switching these to `describe` is less special.
0c5289f
to
5793be5
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me. Thanks, @issyl0!
Thanks again @issyl0! |
Review period ended. |
Have you written new tests for your changes? Here's an example.brew style
with your changes locally?brew typecheck
with your changes locally?brew tests
with your changes locally?brew man
locally and committed any changes?