Skip to content

Commit b4e2d7e

Browse files
committed
Use the latest rubocop-*
1 parent c3534c2 commit b4e2d7e

File tree

3 files changed

+14
-2
lines changed

3 files changed

+14
-2
lines changed

.rubocop.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,14 @@ Performance/DeletePrefix:
131131
Performance/DeleteSuffix:
132132
SafeMultiline: false
133133

134+
RSpec:
135+
Language:
136+
Expectations:
137+
- expect_correction
138+
- expect_no_offenses
139+
- expect_offense
140+
- expect_offense_if_model_file
141+
134142
# This disabling is a workaround for https://github.com/rubocop-hq/rubocop-rails/issues/374.
135143
RSpec/FactoryBot/CreateList:
136144
Enabled: false

Gemfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ gem 'bump', require: false
1010
gem 'rake'
1111
gem 'rspec'
1212
gem 'rubocop', github: 'rubocop/rubocop'
13-
gem 'rubocop-performance', '~> 1.14.0'
14-
gem 'rubocop-rspec', '~> 2.11.0'
13+
gem 'rubocop-performance', '~> 1.15.0'
14+
gem 'rubocop-rspec', '~> 2.13.0'
1515
gem 'simplecov'
1616
gem 'test-queue'
1717
gem 'yard', '~> 0.9'

spec/project_spec.rb

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@
6464
end
6565
end
6666

67+
# rubocop:disable RSpec/NoExpectationExample
6768
it 'has a SupportedStyles for all EnforcedStyle and EnforcedStyle is valid' do
6869
errors = []
6970
cop_names.each do |name|
@@ -83,14 +84,17 @@
8384

8485
raise errors.join("\n") unless errors.empty?
8586
end
87+
# rubocop:enable RSpec/NoExpectationExample
8688

89+
# rubocop:disable RSpec/NoExpectationExample
8790
it 'does not have any duplication' do
8891
fname = File.expand_path('../config/default.yml', __dir__)
8992
content = File.read(fname)
9093
RuboCop::YAMLDuplicationChecker.check(content, fname) do |key1, key2|
9194
raise "#{fname} has duplication of #{key1.value} on line #{key1.start_line} and line #{key2.start_line}"
9295
end
9396
end
97+
# rubocop:enable RSpec/NoExpectationExample
9498

9599
it 'does not include `Safe: true`' do
96100
cop_names.each do |name|

0 commit comments

Comments
 (0)