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

Cop idea: disallow successive not_to include #1650

Open
boris-petrov opened this issue May 24, 2023 · 1 comment
Open

Cop idea: disallow successive not_to include #1650

boris-petrov opened this issue May 24, 2023 · 1 comment
Labels

Comments

@boris-petrov
Copy link

This code:

expect(some_string).not_to include('aaa')
expect(some_string).not_to include('bbb')

Could be written as:

expect(some_string).not_to include('aaa', 'bbb')
@ydah ydah added the cop label May 26, 2023
@Darhazer
Copy link
Member

Same goes for:

expect(some_string).to include('aaa')
expect(some_string).to include('bbb')

Or

expect(some_string).to include('aaa').and include('bbb')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants