-
-
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
Remove extracted cops in Capybara
, FactoryBot
and Rails
departments.
#1848
Conversation
Capybara
, FactoryBot
, Rails
)Capybara
, FactoryBot
and Rails
departments.
VersionAdded: '1.18' | ||
VersionChanged: '2.0' | ||
Reference: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/Capybara/CurrentPathExpectation | ||
|
||
RSpec/Capybara/FeatureMethods: |
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.
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 idea @pirj. I’ve added this as an issue in the 3.0 milestone.
@ydah Now that we have a separate |
I updated this PR. |
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.
👏🏼
It is also a blocker for subsequent PR, so this PR will be merged. We can also follow up. |
In rubocop/rubocop-rspec#1848 rubocop-rspec extracted some cops to separate gems, and because we referenced one of them in our rubocop_todo.yml the whole rubocop process wouldn't run because it doesn't like config for cops it doesn't know about. We introducing the missing gem, `rubocop-rspec_rails`, and fix the name in the config to let us run rubocop again. There is one infraction that exists in the source so we fix that to get us to a green rubocop run.
#939) * Update how we use Rack::Utils to get status codes As part of rack/rack#2137 (released in Rack 3) Rack changed the values of `Rack::Utils::SYMBOL_TO_STATUS_CODE` so asking for `:unprocessable_entity` now returns `nil`. The guidance has always been to use `Rack::Util.status_code` (present in the API since Rack 1.1) so let's just do that. * Handle a missing `rack.input` in the env Ever since rack/rack#2018 `rack.input` has been optional so we can't assume it's there and call `read` or `rewind` on it in `Apipie::Extractor::Recorder`. Using safe navigation to call these methods seems like the simplest approach because we want to look for `rack.request.form_hash` instead in both the situation where `rack.input` is missing, or it's empty. * Add rubocop-rspec_rails and get rubocop run to green In rubocop/rubocop-rspec#1848 rubocop-rspec extracted some cops to separate gems, and because we referenced one of them in our rubocop_todo.yml the whole rubocop process wouldn't run because it doesn't like config for cops it doesn't know about. We introducing the missing gem, `rubocop-rspec_rails`, and fix the name in the config to let us run rubocop again. There is one infraction that exists in the source so we fix that to get us to a green rubocop run. * Only add rubocop-rspec_rails for ruby >-= 2.7 It's only available for 2.7+ and we still run this build on 2.6.
This PR remove extracted cop departments. (
Capybara
,FactoryBot
,Rails
)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).