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
Improve Focus cop #777
Improve Focus cop #777
Conversation
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.
@bquorning @Darhazer Is there anything apart from the missing changelong entry that needs to be addressed here? I believe this may be released together with #804 that bumps RuboCop to the version that provides children matching. |
- Due to the order of how the patterns were defined, the hash capture took priority over the broader capture pattern. I've changed the matching logic to be directly represented by the any-order matcher patterns which also simplifies the code, if just slightly. - Closes #775
- Pending examples are also capable of being focused so I've added them to the examples that are searched for.
43021ea
to
9811446
Compare
Added 1 Changelog commit. Rebased on master (and force-pushed) so we can merge without conflicts. |
@Darhazer @pirj @dgollahon Could one of you please double check that this PR is ready to merge? I’ll rebase #824 afterwards. |
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.
Thanks @bquorning. |
Improves the Focus cop in a couple of ways.
pending
to the examples that it can detect (since these can be focused).fit
. #398 as well but it's actually much trickier than it might first appear.Before submitting the PR make sure the following are checked:
master
(if not - rebase it).bundle exec rake
) passes (be sure to run this locally, since it may produce updated documentation that you will need to commit).