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

Fix an error when using inherit_gem: rubocop-rspec: config/default.yml #1710

Closed
wants to merge 1 commit into from
Closed
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 an error when using `inherit_gem: rubocop-rspec: config/default.yml`. ([@ydah])

## 2.24.0 (2023-09-08)

- Split `RSpec/FilePath` into `RSpec/SpecFilePathSuffix` and `RSpec/SpecFilePathFormat`. `RSpec/FilePath` cop is enabled by default, the two new cops are pending and need to be enabled explicitly. ([@ydah])
Expand Down
6 changes: 0 additions & 6 deletions config/obsoletion.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,3 @@ renamed:
RSpec/FactoryBot/FactoryClassName: FactoryBot/FactoryClassName
RSpec/FactoryBot/FactoryNameStyle: FactoryBot/FactoryNameStyle
RSpec/FactoryBot/SyntaxMethods: FactoryBot/SyntaxMethods

split:
RSpec/FilePath:
alternatives:
- RSpec/SpecFilePathFormat
- RSpec/SpecFilePathSuffix
6 changes: 6 additions & 0 deletions docs/modules/ROOT/pages/cops_rspec.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -2012,6 +2012,12 @@ expect { my_app.print_report }.to output('Hello World').to_stdout

Checks that spec file paths are consistent and well-formed.

This cop is deprecated.
We plan to remove it in the next major version update to 3.0.
The migration destinations are `RSpec/SpecFilePathSuffix`
and `RSpec/SpecFilePathFormat`.
If you are using this cop, please plan for migration.

By default, this checks that spec file paths are consistent with the
test subject and enforces that it reflects the described
class/module and its optionally called out method.
Expand Down
6 changes: 6 additions & 0 deletions lib/rubocop/cop/rspec/file_path.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ module Cop
module RSpec
# Checks that spec file paths are consistent and well-formed.
#
# This cop is deprecated.
# We plan to remove it in the next major version update to 3.0.
# The migration destinations are `RSpec/SpecFilePathSuffix`
# and `RSpec/SpecFilePathFormat`.
# If you are using this cop, please plan for migration.
#
# By default, this checks that spec file paths are consistent with the
# test subject and enforces that it reflects the described
# class/module and its optionally called out method.
Expand Down