Skip to content
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

Merged
merged 3 commits into from Sep 27, 2019
Merged

Improve Focus cop #777

merged 3 commits into from Sep 27, 2019

Conversation

dgollahon
Copy link
Contributor

Improves the Focus cop in a couple of ways.


Before submitting the PR make sure the following are checked:

  • Feature branch is up-to-date with master (if not - rebase it).
  • Squashed related commits together.
  • Added tests.
  • Added an entry to the changelog if the new code introduces user-observable changes.
  • The build (bundle exec rake) passes (be sure to run this locally, since it may produce updated documentation that you will need to commit).

Copy link
Member

@pirj pirj left a comment

Choose a reason for hiding this comment

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

This is good to go after #804
What do you think of shipping this early and addressing #398 separately?

lib/rubocop/cop/rspec/focus.rb Show resolved Hide resolved
@pirj
Copy link
Member

pirj commented Aug 17, 2019

@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.

@pirj pirj mentioned this pull request Aug 18, 2019
@Darhazer Darhazer mentioned this pull request Sep 25, 2019
5 tasks
dgollahon and others added 3 commits September 26, 2019 23:46
- 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.
@bquorning
Copy link
Collaborator

Added 1 Changelog commit. Rebased on master (and force-pushed) so we can merge without conflicts.

@bquorning
Copy link
Collaborator

@Darhazer @pirj @dgollahon Could one of you please double check that this PR is ready to merge? I’ll rebase #824 afterwards.

Copy link
Member

@pirj pirj left a comment

Choose a reason for hiding this comment

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

Looks good.

@bquorning bquorning merged commit def212a into master Sep 27, 2019
@bquorning bquorning deleted the improve-focus-cop branch September 27, 2019 10:12
@dgollahon
Copy link
Contributor Author

Thanks @bquorning.

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.

None yet

4 participants