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

Introduce rspec rubocop #196

Merged
merged 3 commits into from
Nov 7, 2022
Merged

Introduce rspec rubocop #196

merged 3 commits into from
Nov 7, 2022

Conversation

shinsukeimai
Copy link
Contributor

@shinsukeimai shinsukeimai commented Nov 4, 2022

What

Introduces rspec rubocop

Why

In global-web, we disabled rspec rubocop. However, in some cases we would like to point out our coding rule violation. So I add rpsec rubocop.

https://github.com/cookpad/global-web/pull/33185

How

I just added one rule as a first step.
https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/DescribedClass

RSpec/DescribedClass:
EnforcedStyle: explicit

@shinsukeimai shinsukeimai marked this pull request as ready for review November 4, 2022 11:20
Copy link

@tejanium tejanium left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does rubocop have the option to disable all and then enable only what you need one by one?

@Bodacious
Copy link
Contributor

Bodacious commented Nov 4, 2022

Does rubocop have the option to disable all and then enable only what you need one by one?

https://docs.rubocop.org/rubocop/configuration.html#generic-configuration-parameters
DisabledByDefault

@tejanium
Copy link

tejanium commented Nov 4, 2022

Ah nice, I thought it was never implemented rubocop/rubocop#1918 (comment)

@shinsukeimai
Copy link
Contributor Author

dd12839

I checked it works on global-web by fetching via inherit_from.
We can use this not globally if we import it via inherit_from.

@shinsukeimai shinsukeimai merged commit 5517c95 into main Nov 7, 2022
@shinsukeimai shinsukeimai deleted the i-si/introduce-rspec branch November 7, 2022 10:55
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 this pull request may close these issues.

3 participants