-
Notifications
You must be signed in to change notification settings - Fork 7
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
Update rubocop.govuk #5442
Merged
Merged
Update rubocop.govuk #5442
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Bumps [rubocop-govuk](https://github.com/alphagov/rubocop-govuk) from 4.10.0 to 4.11.0. - [Changelog](https://github.com/alphagov/rubocop-govuk/blob/main/CHANGELOG.md) - [Commits](alphagov/rubocop-govuk@v4.10.0...v4.11.0) --- updated-dependencies: - dependency-name: rubocop-govuk dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]>
colinbruce
force-pushed
the
update-rubocop-govuk
branch
4 times, most recently
from
July 5, 2023 10:38
34dd017
to
eb5e294
Compare
colinbruce
force-pushed
the
update-rubocop-govuk
branch
2 times, most recently
from
July 5, 2023 12:00
fd3a3e8
to
6ac3224
Compare
Update factories/hmrc/responses in line with guidance
Address all infringing test harnesses
FactoryBot/FactoryAssociationWithStrategy, exclude spec/factories/legal_aid_applications.rb This is because there are too many traits that create objects that loop back RSpec/IndexedLet, set the max number of spec variables to 2 This will allow up to 2 number let variables e.g. ```ruby let!(:transaction1) { create(:bank_transaction, :benefits, happened_at: 10.days.ago) } let!(:transaction2) { create(:bank_transaction, :benefits, happened_at: 40.days.ago) } ``` But trying to create `transaction3` will raise an error The aim is to slowly reduce the number over time to 1 as we phase out the use of large numbered blocks We also exclude spec/services/cfe/* as the CFE classic integration is due to be deleted soon
colinbruce
force-pushed
the
update-rubocop-govuk
branch
from
July 5, 2023 12:01
6ac3224
to
5adeb2e
Compare
Kudos, SonarCloud Quality Gate passed! 0 Bugs No Coverage information |
jsugarman
reviewed
Jul 5, 2023
jsugarman
approved these changes
Jul 5, 2023
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.
LGTM 👍 - one comment re: contrary cops MatchArray versus ContainExactly. No blockers
naseberry
reviewed
Jul 5, 2023
naseberry
approved these changes
Jul 5, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What
Update the rubocop govuk gem and then step through each update in turn addressing issues that arose
Three exemptions added to
.rubocop.yml
:FactoryBot/FactoryAssociationWithStrategy, exclude spec/factories/legal_aid_applications.rb
This is because there are too many traits that create objects that loop back
RSpec/IndexedLet, set the max number of spec variables to 2
This will allow up to 2 number let variables e.g.
But trying to create
transaction3
will raise an errorThe aim is to slowly reduce the number over time to 1 as we phase out the use of large numbered blocks
Exclude spec/services/cfe/* from RSpec/IndexedLet as the CFE classic integration is due to be deleted soon
Checklist
Before you ask people to review this PR:
bundle exec rake
git rebase main
.