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

DEV: Enable some cops related to RSpec subject #32

Merged
merged 1 commit into from
Jun 26, 2023

Conversation

Flink
Copy link
Contributor

@Flink Flink commented Jun 22, 2023

This PR enables these cops:

  • RSpec/LeadingSubject
  • RSpec/EmptyLineAfterSubject
  • RSpec/NamedSubject

This patch enables these cops:

- `RSpec/LeadingSubject`
- `RSpec/EmptyLineAfterSubject`
- `RSpec/NamedSubject`
@Flink Flink force-pushed the loic-enable-leading-subject branch from 2bc2579 to a0fd05b Compare June 22, 2023 12:40
@@ -8,6 +8,8 @@

let(:config) { RuboCop::Config.new }

before { config["Discourse/NoResetColumnInformationInMigrations"]["Enabled"] = true }
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This cop is disabled by default (always was it seems) but for whatever reason it was working until now.

@Flink Flink requested a review from CvX June 22, 2023 12:42
@Flink
Copy link
Contributor Author

Flink commented Jun 22, 2023

This is a followup of discussions we had on discourse/discourse#22144. To better stick to the RSpec style guide, it’s simpler to enable some of the cops related to subject.

Another PR is already done to make the necessary changes in core: discourse/discourse#22225

@martin-brennan
Copy link
Contributor

Thanks for this @Flink , nice one 🎉

@Flink Flink merged commit 4a86e0b into main Jun 26, 2023
2 checks passed
@Flink Flink deleted the loic-enable-leading-subject branch June 26, 2023 08:42
Flink added a commit to discourse/discourse that referenced this pull request Jun 26, 2023
This enables cops related to RSpec `subject`.

See discourse/rubocop-discourse#32
Flink added a commit to discourse/discourse that referenced this pull request Jun 26, 2023
This enables cops related to RSpec `subject`.

See discourse/rubocop-discourse#32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants