Skip to content

Commit

Permalink
Don't require rubocop/rspec/language/node_pattern
Browse files Browse the repository at this point in the history
The node_pattern file has been removed from rubocop-rspec, and we should
no longer require it.

Also, in rubocop-rspec v3 all the pending cops are now enabled by
default. The `RSpec/FilePath` has been split and
`RSpec/SpecFilePathFormat` can be configured to work instead.
  • Loading branch information
bquorning committed Jun 10, 2024
1 parent 071926a commit c65c676
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 62 deletions.
64 changes: 6 additions & 58 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,16 +98,17 @@ RSpec/ExampleLength:
- heredoc
Max: 11

RSpec/FilePath:
Enabled: false

RSpec/DescribeClass:
Exclude:
- spec/project/**/*.rb

RSpec/MultipleExpectations:
Max: 2

RSpec/SpecFilePathFormat:
CustomTransform:
RSpecRails: rspec_rails

Style/FormatStringToken:
Exclude:
- spec/rubocop/**/*.rb
Expand Down Expand Up @@ -135,58 +136,5 @@ Style/ReturnNilInPredicateMethodDefinition:
Enabled: true

# Enable pending rubocop-rspec cops.

RSpec/BeEmpty:
Enabled: true
RSpec/BeEq:
Enabled: true
RSpec/BeNil:
Enabled: true
RSpec/ChangeByZero:
Enabled: true
RSpec/ClassCheck:
Enabled: true
RSpec/ContainExactly:
Enabled: true
RSpec/DuplicatedMetadata:
Enabled: true
RSpec/EmptyMetadata:
Enabled: true
RSpec/Eq:
Enabled: true
RSpec/ExcessiveDocstringSpacing:
Enabled: true
RSpec/IdenticalEqualityAssertion:
Enabled: true
RSpec/IndexedLet:
Enabled: true
RSpec/IsExpectedSpecify:
Enabled: true
RSpec/MatchArray:
Enabled: true
RSpec/MetadataStyle:
Enabled: true
RSpec/NoExpectationExample:
Enabled: true
RSpec/PendingWithoutReason:
Enabled: true
RSpec/ReceiveMessages:
Enabled: true
RSpec/RedundantAround:
Enabled: true
RSpec/RedundantPredicateMatcher:
Enabled: true
RSpec/RemoveConst:
Enabled: true
RSpec/RepeatedSubjectCall:
Enabled: true
RSpec/SkipBlockInsideExample:
Enabled: true
RSpec/SortMetadata:
Enabled: true
RSpec/SpecFilePathSuffix:
Enabled: true
RSpec/SubjectDeclaration:
Enabled: true
RSpec/VerifiedDoubleReference:
Enabled: true
#
# No pending cops yet.
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ gem 'simplecov', '>= 0.19'
gem 'yard'

# TODO: Move to gemspec when RuboCop RSpec v3 is released.
gem 'rubocop-rspec', '~> 2.27'
gem 'rubocop-rspec', '>= 3.0.0.pre'

local_gemfile = 'Gemfile.local'
eval_gemfile(local_gemfile) if File.exist?(local_gemfile)
3 changes: 0 additions & 3 deletions lib/rubocop-rspec_rails.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@
require 'yaml'

require 'rubocop'

require 'rubocop/rspec/language/node_pattern'

require 'rubocop/rspec/language'

require_relative 'rubocop/rspec_rails/version'
Expand Down

0 comments on commit c65c676

Please sign in to comment.