Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

## Master (Unreleased)

* Fix merging RSpec DSL configuration from third-party gems. ([@pirj][])

## 2.5.0 (2021-09-21)

* Declare autocorrect as unsafe for `ExpectChange`. ([@francois-ferrandis][])
Expand Down
27 changes: 27 additions & 0 deletions config/default.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,20 @@ RSpec:
- "**/*_spec.rb"
- "**/spec/**/*"
Language:
inherit_mode:
merge:
- Expectations
- Helpers
- Hooks
- HookScopes
- Runners
- Subjects
ExampleGroups:
inherit_mode:
merge:
- Regular
- Skipped
- Focused
Regular:
- describe
- context
Expand All @@ -20,6 +33,12 @@ RSpec:
- fcontext
- ffeature
Examples:
inherit_mode:
merge:
- Regular
- Skipped
- Focused
- Pending
Regular:
- it
- specify
Expand Down Expand Up @@ -62,6 +81,10 @@ RSpec:
- all
- suite
Includes:
inherit_mode:
merge:
- Examples
- Context
Examples:
- it_behaves_like
- it_should_behave_like
Expand All @@ -73,6 +96,10 @@ RSpec:
- to_not
- not_to
SharedGroups:
inherit_mode:
merge:
- Examples
- Context
Examples:
- shared_examples
- shared_examples_for
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ RuboCop https://docs.rubocop.org/rubocop/configuration.html#inheriting-configura

== Packaging configuration for RuboCop RSpec

NOTE: Due to a [bug](https://github.com/rubocop/rubocop-rspec/issues/1126), this feature doesn't work properly for `rubocop-rspec` 2.5.0 and earlier versions.

For a third-party gem, it's sufficient to follow three steps:

1. Provide a configuration file (e.g. `.rubocop_rspec_alias_config.yml` or `config/rubocop-rspec.yml`).
Expand Down