-
-
Notifications
You must be signed in to change notification settings - Fork 276
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 new RSpec/IdenticalEqualityAssertion
cop
#1132
Conversation
71b5782
to
eecd3e7
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.
Since it's a new cop, do you mind to run it against https://github.com/pirj/real-world-rspec?
Usually, I remove all .rubocop.yml
files in it manually. And each time I wish rubocop
had an option to ignore config files in the source code.
Looks good in general.
Just a small note regarding the offence message and sanity check against popular repos using RSpec.
Thank you for another contribution!
8ee8c41
to
3db1f43
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.
Perfect. Thank you!
@pirj I ran this cop on |
@tejasbubane 99% look completely legit! expect(true).to eq(true) 😆 Some are ( it("equality") { expect(1).to eq(1) } The only one that is probably a false offence: expect(fqdn_rand(3)).to eql(fqdn_rand(3)) Thank you! BTW, did you feel the pain of removing |
No I ran with |
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.
Good stuff. Only nitpick comments.
a6e9fd7
to
9bdc6c3
Compare
@bquorning Thanks. Fixed as per your comments. |
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.
Thanks!
Do you mind sharing how you do it, @tejasbubane ?
same for
I have those one-liners handy:
and
But I'd rather run |
@pirj Not sure how I ran with
|
Thanks, that works! |
Closes #1130
Before submitting the PR make sure the following are checked:
master
(if not - rebase it).CHANGELOG.md
if the new code introduces user-observable changes.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:
config/default.yml
.Enabled: pending
inconfig/default.yml
.VersionAdded
indefault/config.yml
to the next minor version.