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

Add a new Capybara/NegationMatcherAfterVisit cop #36

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

ydah
Copy link
Member

@ydah ydah commented Apr 3, 2023

Resolve: #7

This PR adds a new Capybara/NegationMatcherAfterVisit cop.


Before submitting the PR make sure the following are checked:

  • Feature branch is up-to-date with main (if not - rebase it).
  • Squashed related commits together.
  • Added tests.
  • Updated documentation.
  • Added an entry to the CHANGELOG.md 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).

If you have created a new cop:

  • Added the new cop to config/default.yml.
  • The cop is configured as Enabled: pending in config/default.yml.
  • The cop documents examples of good and bad code.
  • The tests assert both that bad code is reported and that good code is not reported.
  • Set VersionAdded: "<<next>>" in default/config.yml.

@jdufresne
Copy link

I recently diagnosed and then fixed code in my project that would have benefited from this cop. Any thing I can do to help move it along?

@jdufresne
Copy link

I recently diagnosed and then fixed code in my project that would have benefited from this cop. Any thing I can do to help move it along?

In case it helps, I rebased your work to resolve the merge conflicts: #140

But if this PR resumes, I'm happy to close it in favor of this one.

@pirj
Copy link
Member

pirj commented Jan 9, 2025

@boris-petrov does this look right to you?

@ydah can you please rebase?

@ydah ydah requested a review from a team as a code owner January 9, 2025 05:35
@ydah
Copy link
Member Author

ydah commented Jan 9, 2025

Rebased this PR

Resolve: #7

This PR adds a new `Capybara/NegationMatcherAfterVisit` cop.
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.

Thank you! 🙌

@ydah
Copy link
Member Author

ydah commented Jan 9, 2025

I will wait for @jdufresne response this question before merging.

@pirj
Copy link
Member

pirj commented Jan 9, 2025

What question exactly? I can’t find anything blocking. What am I missing?

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.

Cop idea: disallow calling have_no_XXX immediately after visit (Capybara)
3 participants