armitage-rubocop 1.30.1.1 → 1.51.0.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a2aea611949197183edaecfbfb3998ab3cee962a0c7a129db13cb6dc35852248
4
- data.tar.gz: d2af937152cfed5d829b96ef3f9564afadde3e6ff1c134e256512719aa05eaa2
3
+ metadata.gz: 2153f1ce8cfe4e777b0acb0b7eecc893024bd3294613108b25ad6ac502b68e98
4
+ data.tar.gz: afd933cab780a39cefdfa5f55b9c467ed599b5956a36ee157a888d19db8e3ed9
5
5
  SHA512:
6
- metadata.gz: 054e4be20c1d54e1218b6f8b6f36803fdaa9d046112260181a1c1e12fd0b8de84081b53d668436a9479b0bbf8bdefa71d647dcd07eb463439e2c0f18bb4eeac8
7
- data.tar.gz: 4a4ad946f4e39acb335e582c65f8247bb5dcac53e9d36790e84b2edc62a984623518d923cc9f971cb21e00e3deac117722824c8c499f8e03aa07da09a91bdbf0
6
+ metadata.gz: dace268b9a584c6025e6fa052a19ccd86151729d80f7ba3c94e03e5ecbab534f4628df5ad137f9517aa261af167df7b86876fc72c05025a22170457c8bbf3a3a
7
+ data.tar.gz: bad586be3b076bc666e71e056d5c3e8f63554a6c9fb7b2d4a74067df57d87d35fe592b3ba7478f3e76402fc970b1ad2a207d85886a25add1e15070e66eac017d
data/Gemfile.lock CHANGED
@@ -1,68 +1,78 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- armitage-rubocop (1.30.1.1)
5
- rubocop (= 1.30.1)
6
- rubocop-performance (= 1.14.2)
7
- rubocop-rails (= 2.15.0)
4
+ armitage-rubocop (1.51.0.4)
5
+ rubocop (= 1.51.0)
6
+ rubocop-capybara (= 2.18.0)
7
+ rubocop-factory_bot (= 2.23.1)
8
+ rubocop-performance (= 1.18.0)
9
+ rubocop-rails (= 2.19.1)
8
10
  rubocop-rake (= 0.6.0)
9
- rubocop-rspec (= 2.11.1)
11
+ rubocop-rspec (= 2.22.0)
10
12
 
11
13
  GEM
12
14
  remote: https://rubygems.org/
13
15
  specs:
14
- activesupport (7.0.3)
16
+ activesupport (7.0.5)
15
17
  concurrent-ruby (~> 1.0, >= 1.0.2)
16
18
  i18n (>= 1.6, < 2)
17
19
  minitest (>= 5.1)
18
20
  tzinfo (~> 2.0)
19
21
  ast (2.4.2)
20
22
  coderay (1.1.3)
21
- concurrent-ruby (1.1.10)
22
- i18n (1.10.0)
23
+ concurrent-ruby (1.2.2)
24
+ i18n (1.13.0)
23
25
  concurrent-ruby (~> 1.0)
26
+ json (2.6.3)
24
27
  method_source (1.0.0)
25
- minitest (5.16.0)
26
- parallel (1.22.1)
27
- parser (3.1.2.0)
28
+ minitest (5.18.0)
29
+ parallel (1.23.0)
30
+ parser (3.2.2.1)
28
31
  ast (~> 2.4.1)
29
- pry (0.14.1)
32
+ pry (0.14.2)
30
33
  coderay (~> 1.1)
31
34
  method_source (~> 1.0)
32
- rack (2.2.3.1)
35
+ rack (3.0.7)
33
36
  rainbow (3.1.1)
34
37
  rake (13.0.6)
35
- regexp_parser (2.5.0)
38
+ regexp_parser (2.8.0)
36
39
  rexml (3.2.5)
37
- rubocop (1.30.1)
40
+ rubocop (1.51.0)
41
+ json (~> 2.3)
38
42
  parallel (~> 1.10)
39
- parser (>= 3.1.0.0)
43
+ parser (>= 3.2.0.0)
40
44
  rainbow (>= 2.2.2, < 4.0)
41
45
  regexp_parser (>= 1.8, < 3.0)
42
46
  rexml (>= 3.2.5, < 4.0)
43
- rubocop-ast (>= 1.18.0, < 2.0)
47
+ rubocop-ast (>= 1.28.0, < 2.0)
44
48
  ruby-progressbar (~> 1.7)
45
- unicode-display_width (>= 1.4.0, < 3.0)
46
- rubocop-ast (1.18.0)
47
- parser (>= 3.1.1.0)
48
- rubocop-performance (1.14.2)
49
+ unicode-display_width (>= 2.4.0, < 3.0)
50
+ rubocop-ast (1.28.1)
51
+ parser (>= 3.2.1.0)
52
+ rubocop-capybara (2.18.0)
53
+ rubocop (~> 1.41)
54
+ rubocop-factory_bot (2.23.1)
55
+ rubocop (~> 1.33)
56
+ rubocop-performance (1.18.0)
49
57
  rubocop (>= 1.7.0, < 2.0)
50
58
  rubocop-ast (>= 0.4.0)
51
- rubocop-rails (2.15.0)
59
+ rubocop-rails (2.19.1)
52
60
  activesupport (>= 4.2.0)
53
61
  rack (>= 1.1)
54
- rubocop (>= 1.7.0, < 2.0)
62
+ rubocop (>= 1.33.0, < 2.0)
55
63
  rubocop-rake (0.6.0)
56
64
  rubocop (~> 1.0)
57
- rubocop-rspec (2.11.1)
58
- rubocop (~> 1.19)
59
- ruby-progressbar (1.11.0)
60
- tzinfo (2.0.4)
65
+ rubocop-rspec (2.22.0)
66
+ rubocop (~> 1.33)
67
+ rubocop-capybara (~> 2.17)
68
+ rubocop-factory_bot (~> 2.22)
69
+ ruby-progressbar (1.13.0)
70
+ tzinfo (2.0.6)
61
71
  concurrent-ruby (~> 1.0)
62
- unicode-display_width (2.1.0)
72
+ unicode-display_width (2.4.2)
63
73
 
64
74
  PLATFORMS
65
- arm64-darwin-21
75
+ arm64-darwin-22
66
76
 
67
77
  DEPENDENCIES
68
78
  armitage-rubocop!
@@ -71,4 +81,4 @@ DEPENDENCIES
71
81
  rake (~> 13.0)
72
82
 
73
83
  BUNDLED WITH
74
- 2.3.15
84
+ 2.4.12
data/Rakefile CHANGED
@@ -9,6 +9,8 @@ require 'rubocop-performance'
9
9
  require 'rubocop-rspec'
10
10
  require 'rubocop-rails'
11
11
  require 'rubocop-rake'
12
+ require 'rubocop-capybara'
13
+ require 'rubocop-factory_bot'
12
14
 
13
15
  RuboCop::RakeTask.new(:rubocop) do |t|
14
16
  config_path = File.expand_path(File.join('.rubocop.yml'), __dir__)
@@ -17,6 +19,8 @@ RuboCop::RakeTask.new(:rubocop) do |t|
17
19
  t.requires << 'rubocop-rails'
18
20
  t.requires << 'rubocop-rspec'
19
21
  t.requires << 'rubocop-rake'
22
+ t.requires << 'rubocop-capybara'
23
+ t.requires << 'rubocop-factory_bot'
20
24
  end
21
25
 
22
26
  ARMITAGE_RUBOCOP_PATH = Pathname.new(__FILE__).join('../.rubocop.yml')
@@ -28,7 +32,7 @@ namespace :armitage_rubocop do
28
32
  task :build do
29
33
  build_processes = {
30
34
  code_style_check:
31
- Open3.popen3('bundle exec rake rubocop'),
35
+ Open3.popen3("bundle exec rake rubocop -c #{ARMITAGE_RUBOCOP_PATH}"),
32
36
  cops_validation:
33
37
  Open3.popen3('bundle exec rake armitage_rubocop:validation:recognizable_cops'),
34
38
  yaml_validation:
@@ -39,6 +43,8 @@ namespace :armitage_rubocop do
39
43
  results = {}.tap do |result_data|
40
44
  build_processes.each_pair do |build_type, build_process|
41
45
  # NOTE: build_process => [stdin, stdout, stderr, wtr]
46
+ puts build_process[1].read
47
+ puts build_process[2].read
42
48
  build_result = build_process[3].value.exitstatus
43
49
  result_data[build_type] = build_result
44
50
  end
@@ -4,8 +4,9 @@ lib = File.expand_path('lib', __dir__)
4
4
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
5
5
 
6
6
  Gem::Specification.new do |spec|
7
- spec.version = '1.30.1.1'
7
+ spec.required_ruby_version = '>= 3.1'
8
8
 
9
+ spec.version = '1.51.0.4'
9
10
  spec.name = 'armitage-rubocop'
10
11
  spec.license = 'MIT'
11
12
  spec.authors = ['Rustam Ibragimov']
@@ -22,11 +23,13 @@ Gem::Specification.new do |spec|
22
23
  `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
23
24
  end
24
25
 
25
- spec.add_dependency 'rubocop', '= 1.30.1'
26
- spec.add_dependency 'rubocop-performance', '= 1.14.2'
27
- spec.add_dependency 'rubocop-rails', '= 2.15.0'
28
- spec.add_dependency 'rubocop-rspec', '= 2.11.1'
26
+ spec.add_dependency 'rubocop', '= 1.51.0'
27
+ spec.add_dependency 'rubocop-performance', '= 1.18.0'
28
+ spec.add_dependency 'rubocop-rails', '= 2.19.1'
29
+ spec.add_dependency 'rubocop-rspec', '= 2.22.0'
29
30
  spec.add_dependency 'rubocop-rake', '= 0.6.0'
31
+ spec.add_dependency 'rubocop-capybara', '= 2.18.0'
32
+ spec.add_dependency 'rubocop-factory_bot', '= 2.23.1'
30
33
 
31
34
  spec.add_development_dependency 'bundler', '~> 2.3'
32
35
  spec.add_development_dependency 'rake', '~> 13.0'
@@ -3,6 +3,10 @@ Gemspec/DeprecatedAttributeAssignment:
3
3
  Include:
4
4
  - '**/*.gemspec'
5
5
 
6
+ Gemspec/DevelopmentDependencies:
7
+ Enabled: true
8
+ EnforcedStyle: gemspec
9
+
6
10
  Gemspec/DependencyVersion:
7
11
  Enabled: true
8
12
  EnforcedStyle: required
@@ -10,11 +14,6 @@ Gemspec/DependencyVersion:
10
14
  - '**/*.gemspec'
11
15
  AllowedGems: []
12
16
 
13
- Gemspec/DateAssignment:
14
- Enabled: true
15
- Include:
16
- - '**/*.gemspec'
17
-
18
17
  Gemspec/DuplicatedAssignment:
19
18
  Enabled: true
20
19
 
@@ -23,7 +22,7 @@ Gemspec/OrderedDependencies:
23
22
  TreatCommentsAsGroupSeparators: true
24
23
 
25
24
  Gemspec/RequiredRubyVersion:
26
- Enabled: false
25
+ Enabled: true
27
26
 
28
27
  Gemspec/RubyVersionGlobalsUsage:
29
28
  Enabled: true
@@ -233,6 +233,16 @@ Layout/LeadingCommentSpace:
233
233
  AllowDoxygenCommentStyle: false
234
234
  AllowGemfileRubyComment: true
235
235
 
236
+ Layout/LineContinuationLeadingSpace:
237
+ Enabled: true
238
+ AutoCorrect: true
239
+ EnforcedStyle: trailing
240
+
241
+ Layout/LineContinuationSpacing:
242
+ Enabled: true
243
+ EnforcedStyle: space
244
+ AutoCorrect: true
245
+
236
246
  Layout/LineLength:
237
247
  Enabled: true
238
248
  AutoCorrect: true
@@ -247,6 +257,10 @@ Layout/LineLength:
247
257
  Exclude:
248
258
  - Gemfile
249
259
 
260
+ Layout/MultilineMethodParameterLineBreaks:
261
+ Enabled: true
262
+ AllowMultilineFinalElement: true
263
+
250
264
  Layout/MultilineArrayBraceLayout:
251
265
  Enabled: true
252
266
  EnforcedStyle: symmetrical
@@ -281,12 +295,15 @@ Layout/MultilineOperationIndentation:
281
295
 
282
296
  Layout/MultilineHashKeyLineBreaks:
283
297
  Enabled: false
298
+ AllowMultilineFinalElement: false
284
299
 
285
300
  Layout/MultilineMethodArgumentLineBreaks:
286
301
  Enabled: false
302
+ AllowMultilineFinalElement: true
287
303
 
288
304
  Layout/MultilineArrayLineBreaks:
289
305
  Enabled: false
306
+ AllowMultilineFinalElement: true
290
307
 
291
308
  Layout/RescueEnsureAlignment:
292
309
  Enabled: true
data/lib/common/lint.yml CHANGED
@@ -2,7 +2,8 @@ Lint/AmbiguousAssignment:
2
2
  Enabled: false
3
3
 
4
4
  Lint/AmbiguousBlockAssociation:
5
- IgnoredMethods: []
5
+ AllowedMethods: []
6
+ AutoCorrect: true
6
7
  Enabled: true
7
8
 
8
9
  Lint/AmbiguousOperator:
@@ -20,6 +21,7 @@ Lint/AmbiguousOperatorPrecedence:
20
21
 
21
22
  Lint/AssignmentInCondition:
22
23
  Enabled: false
24
+ AutoCorrect: true
23
25
  AllowSafeAssignment: true
24
26
 
25
27
  Lint/BigDecimalNew:
@@ -39,6 +41,9 @@ Lint/ConstantDefinitionInBlock:
39
41
  AllowedMethods:
40
42
  - enums
41
43
 
44
+ Lint/ConstantOverwrittenInRescue:
45
+ Enabled: true
46
+
42
47
  Lint/ConstantResolution:
43
48
  Enabled: false
44
49
  Only: []
@@ -60,6 +65,12 @@ Lint/DisjunctiveAssignmentInConstructor:
60
65
  Enabled: true
61
66
  AutoCorrect: false
62
67
 
68
+ Lint/DuplicateMatchPattern:
69
+ Enabled: true
70
+
71
+ Lint/DuplicateMagicComment:
72
+ Enabled: true
73
+
63
74
  Lint/DuplicateBranch:
64
75
  Enabled: true
65
76
  IgnoreLiteralBranches: false
@@ -110,6 +121,7 @@ Lint/EmptyInPattern:
110
121
  Lint/EmptyConditionalBody:
111
122
  Enabled: true
112
123
  AllowComments: true
124
+ AutoCorrect: true
113
125
 
114
126
  Lint/EmptyEnsure:
115
127
  Enabled: true
@@ -226,6 +238,9 @@ Lint/NestedPercentLiteral:
226
238
  Lint/NextWithoutAccumulator:
227
239
  Enabled: true
228
240
 
241
+ Lint/NonAtomicFileOperation:
242
+ Enabled: true
243
+
229
244
  Lint/NonDeterministicRequireOrder:
230
245
  Enabled: false
231
246
 
@@ -257,9 +272,15 @@ Lint/PercentStringArray:
257
272
  Lint/PercentSymbolArray:
258
273
  Enabled: true
259
274
 
275
+ Lint/UselessElseWithoutRescue:
276
+ Enabled: true
277
+
260
278
  Lint/UselessRuby2Keywords:
261
279
  Enabled: true
262
280
 
281
+ Lint/UselessRescue:
282
+ Enabled: true
283
+
263
284
  Lint/RaiseException:
264
285
  Enabled: true
265
286
  AutoCorrect: false
@@ -295,6 +316,9 @@ Lint/RegexpAsCondition:
295
316
  Enabled: true
296
317
  AutoCorrect: true
297
318
 
319
+ Lint/RequireRangeParentheses:
320
+ Enabled: true
321
+
298
322
  Lint/RequireParentheses:
299
323
  Enabled: true
300
324
 
@@ -346,6 +370,7 @@ Lint/ToJSON:
346
370
  Enabled: true
347
371
 
348
372
  Lint/TopLevelReturnWithArgument:
373
+ AutoCorrect: true
349
374
  Enabled: true
350
375
 
351
376
  Lint/TrailingCommaInAttributeDeclaration:
@@ -412,6 +437,7 @@ Lint/UselessAccessModifier:
412
437
  AutoCorrect: true
413
438
 
414
439
  Lint/UselessAssignment:
440
+ AutoCorrect: true
415
441
  Enabled: true
416
442
 
417
443
  Lint/UselessMethodDefinition:
@@ -425,5 +451,6 @@ Lint/UselessTimes:
425
451
  Enabled: true
426
452
 
427
453
  Lint/Void:
454
+ AutoCorrect: true
428
455
  Enabled: true
429
456
  CheckForMethodsWithNoSideEffects: false
@@ -2,14 +2,14 @@ Metrics/AbcSize:
2
2
  Enabled: true
3
3
  Max: 19
4
4
  CountRepeatedAttributes: true
5
- IgnoredMethods: []
5
+ AllowedMethods: []
6
6
 
7
7
  Metrics/BlockLength:
8
8
  Enabled: true
9
9
  CountComments: false
10
10
  CountAsOne: []
11
11
  Max: 25
12
- IgnoredMethods:
12
+ AllowedMethods:
13
13
  - refine
14
14
  Exclude:
15
15
  - Rakefile
@@ -21,6 +21,9 @@ Metrics/BlockNesting:
21
21
  CountBlocks: false
22
22
  Max: 3
23
23
 
24
+ Metrics/CollectionLiteralLength:
25
+ Enabled: false
26
+
24
27
  Metrics/ClassLength:
25
28
  Enabled: true
26
29
  CountComments: false
@@ -29,14 +32,14 @@ Metrics/ClassLength:
29
32
  Metrics/CyclomaticComplexity:
30
33
  Enabled: true
31
34
  Max: 10
32
- IgnoredMethods: []
35
+ AllowedMethods: []
33
36
 
34
37
  Metrics/MethodLength:
35
38
  Enabled: true
36
39
  Max: 25
37
40
  CountComments: false
38
41
  CountAsOne: []
39
- IgnoredMethods: []
42
+ AllowedMethods: []
40
43
 
41
44
  Metrics/ModuleLength:
42
45
  Enabled: true
@@ -52,4 +55,4 @@ Metrics/ParameterLists:
52
55
  Metrics/PerceivedComplexity:
53
56
  Enabled: true
54
57
  Max: 10
55
- IgnoredMethods: []
58
+ AllowedMethods: []
@@ -74,6 +74,11 @@ Naming/MethodParameterName:
74
74
  - 'ip'
75
75
  - 'db'
76
76
  - 'os'
77
+ - 'as'
78
+ - 'if'
79
+ - 'cc'
80
+ - 'of'
81
+ - 'pp'
77
82
  ForbiddenNames: []
78
83
 
79
84
  Naming/VariableName:
data/lib/common/rails.yml CHANGED
@@ -8,6 +8,9 @@ Rails/ActionFilter:
8
8
  Enabled: true
9
9
  EnforcedStyle: action
10
10
 
11
+ Rails/ActionOrder:
12
+ Enabled: false
13
+
11
14
  Rails/ActiveRecordAliases:
12
15
  Enabled: true
13
16
 
@@ -54,6 +57,9 @@ Rails/AttributeDefaultBlockValue:
54
57
  Rails/ArelStar:
55
58
  Enabled: true
56
59
 
60
+ Rails/ResponseParsedBody:
61
+ Enabled: false
62
+
57
63
  Rails/RequireDependency:
58
64
  Enabled: true
59
65
  # NOTE: `require_dependency` is obsolete when you use `Zeitwerk`
@@ -183,6 +189,9 @@ Rails/MigrationClassName:
183
189
  Rails/I18nLocaleAssignment:
184
190
  Enabled: false
185
191
 
192
+ Rails/IgnoredColumnsAssignment:
193
+ Enabled: true
194
+
186
195
  Rails/IgnoredSkipActionFilterOption:
187
196
  Enabled: true
188
197
 
@@ -273,6 +282,7 @@ Rails/RedundantReceiverInWithOptions:
273
282
 
274
283
  Rails/ReflectionClassName:
275
284
  Enabled: true
285
+ AutoCorrect: true
276
286
 
277
287
  Rails/RefuteMethods:
278
288
  Enabled: true
@@ -330,6 +340,9 @@ Rails/StripHeredoc:
330
340
  Rails/RedundantTravelBack:
331
341
  Enabled: false # NOTE: can affect the readability
332
342
 
343
+ Rails/ThreeStateBooleanColumn:
344
+ Enabled: false
345
+
333
346
  Rails/TableNameAssignment:
334
347
  Enabled: false
335
348
 
@@ -366,6 +379,9 @@ Rails/UnknownEnv:
366
379
  Rails/Validation:
367
380
  Enabled: true
368
381
 
382
+ Rails/WhereNotWithMultipleConditions:
383
+ Enabled: false
384
+
369
385
  Rails/WhereEquals:
370
386
  Enabled: true
371
387
 
@@ -375,3 +391,24 @@ Rails/WhereExists:
375
391
 
376
392
  Rails/WhereNot:
377
393
  Enabled: false
394
+
395
+ Rails/FreezeTime:
396
+ Enabled: true
397
+
398
+ Rails/WhereMissing:
399
+ Enabled: false
400
+
401
+ Rails/RootPathnameMethods:
402
+ Enabled: true
403
+
404
+ Rails/TopLevelHashWithIndifferentAccess:
405
+ Enabled: true
406
+
407
+ Rails/ActionControllerFlashBeforeRender:
408
+ Enabled: true
409
+
410
+ Rails/ActiveSupportOnLoad:
411
+ Enabled: true
412
+
413
+ Rails/ToSWithArgument:
414
+ Enabled: true
data/lib/common/style.yml CHANGED
@@ -15,6 +15,9 @@ Style/AndOr:
15
15
  Enabled: false
16
16
  EnforcedStyle: always
17
17
 
18
+ Style/ArrayIntersect:
19
+ Enabled: true
20
+
18
21
  Style/ArrayCoercion:
19
22
  Enabled: true
20
23
 
@@ -57,10 +60,12 @@ Style/BlockDelimiters:
57
60
  Style/CaseEquality:
58
61
  Enabled: true
59
62
  AllowOnConstant: false
63
+ AllowOnSelfClass: false
60
64
  AutoCorrect: true
61
65
 
62
66
  Style/CaseLikeIf:
63
67
  Enabled: true
68
+ MinBranchesCount: 3
64
69
  AutoCorrect: true
65
70
 
66
71
  Style/CharacterLiteral:
@@ -75,7 +80,7 @@ Style/ClassCheck:
75
80
 
76
81
  Style/ClassEqualityComparison:
77
82
  Enabled: true
78
- IgnoredMethods:
83
+ AllowedMethods:
79
84
  - ==
80
85
  - equal?
81
86
  - eql?
@@ -90,6 +95,9 @@ Style/ClassMethodsDefinitions:
90
95
  Style/ClassVars:
91
96
  Enabled: true
92
97
 
98
+ Style/ConcatArrayLiterals:
99
+ Enabled: false # NOTE: it is totally unsafe
100
+
93
101
  Style/CollectionCompact:
94
102
  Enabled: true
95
103
 
@@ -102,6 +110,9 @@ Style/ColonMethodCall:
102
110
  Style/ColonMethodDefinition:
103
111
  Enabled: true
104
112
 
113
+ Style/ComparableClamp:
114
+ Enabled: true
115
+
105
116
  Style/CombinableLoops:
106
117
  Enabled: false
107
118
 
@@ -124,6 +135,9 @@ Style/ConstantVisibility:
124
135
  Style/Copyright:
125
136
  Enabled: false
126
137
 
138
+ Style/DataInheritance:
139
+ Enabled: true
140
+
127
141
  Style/DateTime:
128
142
  Enabled: false
129
143
  AllowCoercion: false
@@ -135,6 +149,9 @@ Style/DefWithParentheses:
135
149
  Style/Dir:
136
150
  Enabled: true
137
151
 
152
+ Style/DirEmpty:
153
+ Enabled: true
154
+
138
155
  Style/DisableCopsWithinSourceCodeDirective:
139
156
  Enabled: false
140
157
 
@@ -158,6 +175,9 @@ Style/EachForSimpleLoop:
158
175
  Style/EachWithObject:
159
176
  Enabled: true
160
177
 
178
+ Style/EmptyHeredoc:
179
+ Enabled: true
180
+
161
181
  Style/EmptyBlockParameter:
162
182
  Enabled: true
163
183
 
@@ -167,6 +187,7 @@ Style/EmptyCaseCondition:
167
187
  Style/EmptyElse:
168
188
  Enabled: true
169
189
  EnforcedStyle: empty
190
+ AllowComments: true
170
191
 
171
192
  Style/EmptyLambdaParameter:
172
193
  Enabled: true
@@ -199,6 +220,9 @@ Style/EvalWithLocation:
199
220
  Style/EvenOdd:
200
221
  Enabled: true
201
222
 
223
+ Style/ExactRegexpMatch:
224
+ Enabled: true
225
+
202
226
  Style/ExpandPathArguments:
203
227
  Enabled: true
204
228
 
@@ -210,7 +234,10 @@ Style/ExplicitBlockArgument:
210
234
  Enabled: true
211
235
 
212
236
  Style/FetchEnvVar:
213
- Enabled: false
237
+ Enabled: true
238
+
239
+ Style/FileEmpty:
240
+ Enabled: true
214
241
 
215
242
  Style/FileRead:
216
243
  Enabled: false
@@ -234,7 +261,7 @@ Style/FormatStringToken:
234
261
  Enabled: true
235
262
  MaxUnannotatedPlaceholdersAllowed: 1
236
263
  EnforcedStyle: annotated
237
- IgnoredMethods: []
264
+ AllowedMethods: []
238
265
 
239
266
  Style/FrozenStringLiteralComment:
240
267
  Enabled: true
@@ -249,6 +276,7 @@ Style/GlobalStdStream:
249
276
 
250
277
  Style/GuardClause:
251
278
  Enabled: false
279
+ AutoCorrect: true
252
280
  MinBodyLength: 1
253
281
  AllowConsecutiveConditionals: false
254
282
 
@@ -309,6 +337,9 @@ Style/IfWithSemicolon:
309
337
  Style/ImplicitRuntimeError:
310
338
  Enabled: false
311
339
 
340
+ Style/InvertibleUnlessCondition:
341
+ Enabled: false
342
+
312
343
  Style/InfiniteLoop:
313
344
  Enabled: true
314
345
 
@@ -334,6 +365,15 @@ Style/LambdaCall:
334
365
  Style/LineEndConcatenation:
335
366
  Enabled: true
336
367
 
368
+ Style/MagicCommentFormat:
369
+ Enabled: true
370
+ EnforcedStyle: snake_case
371
+ DirectiveCapitalization: lowercase
372
+ ValueCapitalization: ~
373
+
374
+ Style/MapToSet:
375
+ Enabled: false # NOTE: it is totally unsafe
376
+
337
377
  Style/MapCompactWithConditionalBlock:
338
378
  Enabled: true
339
379
 
@@ -362,8 +402,12 @@ Style/MethodDefParentheses:
362
402
  Style/MinMax:
363
403
  Enabled: true
364
404
 
405
+ Style/MinMaxComparison:
406
+ Enabled: true
407
+
365
408
  Style/MissingElse:
366
409
  Enabled: false
410
+ AutoCorrect: true
367
411
 
368
412
  Style/MissingRespondToMissing:
369
413
  Enabled: true
@@ -472,16 +516,17 @@ Style/NumericLiterals:
472
516
  Enabled: true
473
517
  Strict: false
474
518
  AllowedNumbers: []
519
+ AllowedPatterns: []
475
520
 
476
521
  Style/NumericPredicate:
477
522
  Enabled: false # strongly situative cop
478
523
  EnforcedStyle: comparison
479
524
  AutoCorrect: true
480
- IgnoredMethods: []
525
+ AllowedMethods: []
481
526
 
482
527
  Style/ObjectThen:
483
528
  Enabled: true
484
- EnforcedStyle: then
529
+ EnforcedStyle: yield_self
485
530
 
486
531
  Style/OneLineConditional:
487
532
  Enabled: true
@@ -489,6 +534,9 @@ Style/OneLineConditional:
489
534
  Style/OpenStructUse:
490
535
  Enabled: true
491
536
 
537
+ Style/OperatorMethodCall:
538
+ Enabled: true
539
+
492
540
  Style/OptionHash:
493
541
  Enabled: false
494
542
 
@@ -531,6 +579,24 @@ Style/RaiseArgs:
531
579
  Style/RandomWithOffset:
532
580
  Enabled: true
533
581
 
582
+ Style/RedundantLineContinuation:
583
+ Enabled: true
584
+
585
+ Style/RedundantHeredocDelimiterQuotes:
586
+ Enabled: true
587
+
588
+ Style/RedundantConstantBase:
589
+ Enabled: true
590
+
591
+ Style/RequireOrder:
592
+ Enabled: false
593
+
594
+ Style/RedundantEach:
595
+ Enabled: true
596
+
597
+ Style/RedundantStringEscape:
598
+ Enabled: true
599
+
534
600
  Style/RedundantArgument:
535
601
  Enabled: false
536
602
 
@@ -644,6 +710,7 @@ Style/SpecialGlobalVars:
644
710
 
645
711
  Style/StaticClass:
646
712
  Enabled: true
713
+ AutoCorrect: true
647
714
 
648
715
  Style/StabbyLambdaParentheses:
649
716
  Enabled: true
@@ -692,9 +759,9 @@ Style/SymbolProc:
692
759
  Enabled: true
693
760
  AllowMethodsWithArguments: true
694
761
  AllowComments: false
695
- IgnoredMethods:
696
- - respond_to
762
+ AllowedMethods:
697
763
  - define_method
764
+ - mail
698
765
 
699
766
  Style/SwapValues:
700
767
  Enabled: true
@@ -749,6 +816,9 @@ Style/UnlessLogicalOperators:
749
816
  EnforcedStyle: forbid_mixed_logical_operators
750
817
  Enabled: false
751
818
 
819
+ Style/RedundantDoubleSplatHashBraces:
820
+ Enabled: true
821
+
752
822
  Style/RedundantCapitalW:
753
823
  Enabled: true
754
824
 
@@ -793,6 +863,9 @@ Style/YodaCondition:
793
863
  Enabled: false
794
864
  EnforcedStyle: forbid_for_all_comparison_operators
795
865
 
866
+ Style/YodaExpression:
867
+ Enabled: false
868
+
796
869
  Style/ZeroLengthPredicate:
797
870
  Enabled: true
798
871
 
@@ -1,8 +1,23 @@
1
- RSpec/Capybara/CurrentPathExpectation:
1
+ Capybara/CurrentPathExpectation:
2
2
  Enabled: true
3
3
 
4
- RSpec/Capybara/FeatureMethods:
4
+ Capybara/FeatureMethods:
5
5
  Enabled: false
6
6
 
7
- RSpec/Capybara/VisibilityMatcher:
7
+ Capybara/VisibilityMatcher:
8
+ Enabled: true
9
+
10
+ Capybara/SpecificMatcher:
11
+ Enabled: false
12
+
13
+ Capybara/SpecificFinders:
14
+ Enabled: false
15
+
16
+ Capybara/NegationMatcher:
17
+ Enabled: false
18
+
19
+ Capybara/SpecificActions:
20
+ Enabled: true
21
+
22
+ Capybara/MatchStyle:
8
23
  Enabled: true
@@ -1,12 +1,31 @@
1
- RSpec/FactoryBot/AttributeDefinedStatically:
1
+ FactoryBot/AttributeDefinedStatically:
2
2
  Enabled: false
3
3
 
4
- RSpec/FactoryBot/CreateList:
4
+ FactoryBot/CreateList:
5
5
  Enabled: true
6
6
  EnforcedStyle: create_list
7
+ ExplicitOnly: false
7
8
 
8
- RSpec/FactoryBot/FactoryClassName:
9
+ FactoryBot/FactoryClassName:
9
10
  Enabled: true
10
11
 
11
- RSpec/FactoryBot/SyntaxMethods:
12
+ FactoryBot/SyntaxMethods:
12
13
  Enabled: true
14
+
15
+ FactoryBot/ConsistentParenthesesStyle:
16
+ Enabled: true
17
+ ExplicitOnly: false
18
+
19
+ FactoryBot/FactoryNameStyle:
20
+ Enabled: true
21
+ EnforcedStyle: symbol
22
+ ExplicitOnly: false
23
+
24
+ FactoryAssociationWithStrategy:
25
+ Enabled: false
26
+
27
+ FactoryBot/RedundantFactoryOption:
28
+ Enabled: false
29
+
30
+ FactoryBot/AssociationStyle:
31
+ Enabled: false
data/lib/rspec/rails.yml CHANGED
@@ -3,3 +3,15 @@ RSpec/Rails/HttpStatus:
3
3
 
4
4
  RSpec/Rails/AvoidSetupHook:
5
5
  Enabled: true
6
+
7
+ RSpec/Rails/HaveHttpStatus:
8
+ Enabled: false
9
+
10
+ RSpec/Rails/InferredSpecType:
11
+ Enabled: false
12
+
13
+ RSpec/Rails/MinitestAssertions:
14
+ Enabled: true
15
+
16
+ RSpec/Rails/TravelAround:
17
+ Enabled: false
data/lib/rspec/rspec.yml CHANGED
@@ -17,18 +17,31 @@ RSpec/BeNil:
17
17
  Enabled: false
18
18
  EnforcedStyle: be
19
19
 
20
+ RSpec/BeEmpty:
21
+ Enabled: false
22
+
20
23
  RSpec/BeEql:
21
24
  Enabled: false
22
25
 
23
26
  RSpec/BeforeAfterAll:
24
27
  Enabled: false
25
28
 
29
+ RSpec/ChangeByZero:
30
+ Enabled: true
31
+ NegatedMatcher: ~
32
+
33
+ RSpec/ContainExactly:
34
+ Enabled: false
35
+
26
36
  RSpec/ContextMethod:
27
37
  Enabled: false
28
38
 
29
39
  RSpec/ContextWording:
30
40
  Enabled: false
31
41
 
42
+ RSpec/DuplicatedMetadata:
43
+ Enabled: true
44
+
32
45
  RSpec/DescribeClass:
33
46
  Enabled: false
34
47
 
@@ -52,10 +65,14 @@ RSpec/Dialect:
52
65
 
53
66
  RSpec/EmptyExampleGroup:
54
67
  Enabled: true
68
+ AutoCorrect: true
55
69
 
56
70
  RSpec/EmptyHook:
57
71
  Enabled: true
58
72
 
73
+ RSpec/NoExpectationExample:
74
+ Enabled: false
75
+
59
76
  RSpec/EmptyLineAfterExampleGroup:
60
77
  Enabled: true
61
78
 
@@ -67,6 +84,7 @@ RSpec/EmptyLineAfterFinalLet:
67
84
 
68
85
  RSpec/EmptyLineAfterHook:
69
86
  Enabled: true
87
+ AllowConsecutiveOneLiners: true
70
88
 
71
89
  RSpec/EmptyLineAfterSubject:
72
90
  Enabled: true
@@ -127,6 +145,9 @@ RSpec/ImplicitSubject:
127
145
  RSpec/InstanceSpy:
128
146
  Enabled: true
129
147
 
148
+ RSpec/IndexedLet:
149
+ Enabled: false
150
+
130
151
  RSpec/InstanceVariable:
131
152
  Enabled: true
132
153
  AssignmentOnly: false
@@ -150,6 +171,9 @@ RSpec/LetBeforeExamples:
150
171
  RSpec/LetSetup:
151
172
  Enabled: false
152
173
 
174
+ RSpec/MatchArray:
175
+ Enabled: false
176
+
153
177
  RSpec/MessageChain:
154
178
  Enabled: false
155
179
 
@@ -177,6 +201,7 @@ RSpec/MultipleSubjects:
177
201
  RSpec/NamedSubject:
178
202
  Enabled: true
179
203
  IgnoreSharedExamples: true
204
+ EnforcedStyle: always
180
205
 
181
206
  RSpec/NestedGroups:
182
207
  Enabled: false
@@ -191,6 +216,9 @@ RSpec/OverwritingSetup:
191
216
  RSpec/Pending:
192
217
  Enabled: false
193
218
 
219
+ RSpec/PendingWithoutReason:
220
+ Enabled: false
221
+
194
222
  RSpec/PredicateMatcher:
195
223
  Enabled: true
196
224
  Strict: true
@@ -201,6 +229,9 @@ RSpec/PredicateMatcher:
201
229
  - have_http_status
202
230
  - have_been_made
203
231
 
232
+ RSpec/RedundantAround:
233
+ Enabled: true
234
+
204
235
  RSpec/ReceiveCounts:
205
236
  Enabled: false
206
237
 
@@ -226,11 +257,22 @@ RSpec/ReturnFromStub:
226
257
  Enabled: true
227
258
  EnforcedStyle: and_return
228
259
 
260
+ RSpec/ClassCheck:
261
+ Enabled: true
262
+ EnforcedStyle: be_a
263
+
264
+ RSpec/SkipBlockInsideExample:
265
+ Enabled: true
266
+
267
+ RSpec/SortMetadata:
268
+ Enabled: false
269
+
229
270
  RSpec/ScatteredLet:
230
271
  Enabled: true
231
272
 
232
273
  RSpec/ScatteredSetup:
233
274
  Enabled: false
275
+ AutoCorrect: true
234
276
 
235
277
  RSpec/SharedContext:
236
278
  Enabled: true
@@ -260,7 +302,7 @@ RSpec/VariableDefinition:
260
302
  RSpec/VariableName:
261
303
  Enabled: true
262
304
  EnforcedStyle: snake_case
263
- IgnoredPatterns: []
305
+ AllowedPatterns: []
264
306
 
265
307
  RSpec/VerifiedDoubles:
266
308
  Enabled: false
@@ -18,4 +18,5 @@ AllCops:
18
18
  DisplayStyleGuide: false
19
19
  ExtraDetails: true
20
20
  UseCache: false
21
+ ActiveSupportExtensionsEnabled: false
21
22
  TargetRubyVersion: ~
@@ -8,6 +8,7 @@ inherit_from:
8
8
 
9
9
  AllCops:
10
10
  TargetRailsVersion: ~
11
+ ActiveSupportExtensionsEnabled: true
11
12
 
12
13
  Rails:
13
14
  Enabled: true
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: armitage-rubocop
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.30.1.1
4
+ version: 1.51.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rustam Ibragimov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-06-18 00:00:00.000000000 Z
11
+ date: 2023-05-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rubocop
@@ -16,56 +16,56 @@ dependencies:
16
16
  requirements:
17
17
  - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: 1.30.1
19
+ version: 1.51.0
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - '='
25
25
  - !ruby/object:Gem::Version
26
- version: 1.30.1
26
+ version: 1.51.0
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rubocop-performance
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - '='
32
32
  - !ruby/object:Gem::Version
33
- version: 1.14.2
33
+ version: 1.18.0
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - '='
39
39
  - !ruby/object:Gem::Version
40
- version: 1.14.2
40
+ version: 1.18.0
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: rubocop-rails
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - '='
46
46
  - !ruby/object:Gem::Version
47
- version: 2.15.0
47
+ version: 2.19.1
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - '='
53
53
  - !ruby/object:Gem::Version
54
- version: 2.15.0
54
+ version: 2.19.1
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: rubocop-rspec
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - '='
60
60
  - !ruby/object:Gem::Version
61
- version: 2.11.1
61
+ version: 2.22.0
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - '='
67
67
  - !ruby/object:Gem::Version
68
- version: 2.11.1
68
+ version: 2.22.0
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: rubocop-rake
71
71
  requirement: !ruby/object:Gem::Requirement
@@ -80,6 +80,34 @@ dependencies:
80
80
  - - '='
81
81
  - !ruby/object:Gem::Version
82
82
  version: 0.6.0
83
+ - !ruby/object:Gem::Dependency
84
+ name: rubocop-capybara
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - '='
88
+ - !ruby/object:Gem::Version
89
+ version: 2.18.0
90
+ type: :runtime
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - '='
95
+ - !ruby/object:Gem::Version
96
+ version: 2.18.0
97
+ - !ruby/object:Gem::Dependency
98
+ name: rubocop-factory_bot
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - '='
102
+ - !ruby/object:Gem::Version
103
+ version: 2.23.1
104
+ type: :runtime
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - '='
109
+ - !ruby/object:Gem::Version
110
+ version: 2.23.1
83
111
  - !ruby/object:Gem::Dependency
84
112
  name: bundler
85
113
  requirement: !ruby/object:Gem::Requirement
@@ -173,14 +201,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
173
201
  requirements:
174
202
  - - ">="
175
203
  - !ruby/object:Gem::Version
176
- version: '0'
204
+ version: '3.1'
177
205
  required_rubygems_version: !ruby/object:Gem::Requirement
178
206
  requirements:
179
207
  - - ">="
180
208
  - !ruby/object:Gem::Version
181
209
  version: '0'
182
210
  requirements: []
183
- rubygems_version: 3.3.11
211
+ rubygems_version: 3.4.12
184
212
  signing_key:
185
213
  specification_version: 4
186
214
  summary: A set of rubocop settings