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

Update v3 migration guide with new gem names #1926

Closed
bmulholland opened this issue Jun 18, 2024 · 4 comments · Fixed by #1927
Closed

Update v3 migration guide with new gem names #1926

bmulholland opened this issue Jun 18, 2024 · 4 comments · Fixed by #1927

Comments

@bmulholland
Copy link
Contributor

bmulholland commented Jun 18, 2024

v3 upgrade says "If you are using the RSpec/Capybara, RSpec/FactoryBot, or RSpec/Rails departments, you need to install the corresponding gem"

But what are the corresponding gems? The doc lists "rubocop-capybara." We already have rubocop-rails installed. Is that it? And is the other one https://github.com/rubocop/rubocop-factory_bot ? Both well predate the v3 extraction, so it seems unlikely those are newly split.

@bmulholland
Copy link
Contributor Author

Looks like they are rubocop-rspec_rails and rubocop-factory_bot

@bmulholland bmulholland changed the title v3 new gem names? Update v3 migration guide with new gem names Jun 18, 2024
@GeoffKarnov
Copy link

I got the error: cannot load such file -- rubocop-rspec_rails
So I added gem "rubocop-rspec_rails", require: false to my gemfile.

@pirj
Copy link
Member

pirj commented Jun 18, 2024

Hey @bmulholland 👋

The previously reported “cannot load such file” issue can be fixed by running rubocop --restart-server as suggested here. My apologies for the inconvenience.

A PR to add gem names to the update guide is welcome!
I was under the impression that rubocop would suggest extensions basing on the contents of the Gemfile, but this can be silenced or fail to work.

@bmulholland
Copy link
Contributor Author

Hey @pirj ! Hope you're well :)

Happy to submit a PR to update the docs. I think this is the canonical version, is that right? https://docs.rubocop.org/rubocop-rspec/upgrade_to_version_3.html -- submitted #1927 to resolve this, including your troubleshooting suggestion. Doing this as a quick contribution, please let me know if I missed anything.

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 a pull request may close this issue.

3 participants