rmagick 5.5.0 → 6.0.1

Sign up to get free protection for your applications and to get access to all the features.
data/.rubocop_todo.yml CHANGED
@@ -1,36 +1,35 @@
1
1
  # This configuration was generated by
2
2
  # `rubocop --auto-gen-config`
3
- # on 2020-10-10 21:34:21 +0900 using RuboCop version 0.81.0.
3
+ # on 2024-04-18 19:59:34 UTC using RuboCop version 1.63.2.
4
4
  # The point is for the user to remove these configuration records
5
5
  # one by one as the offenses are removed from the code base.
6
6
  # Note that changes in the inspected code, or installation of new
7
7
  # versions of RuboCop, may require this file to be generated again.
8
8
 
9
- # Offense count: 9
10
- # Configuration parameters: Include, IgnoredGems.
9
+ # Offense count: 11
10
+ # Configuration parameters: Include, IgnoredGems, OnlyFor.
11
11
  # Include: **/*.gemfile, **/Gemfile, **/gems.rb
12
12
  Bundler/GemComment:
13
13
  Exclude:
14
14
  - 'Gemfile'
15
15
 
16
16
  # Offense count: 1
17
- # Cop supports --auto-correct.
18
- # Configuration parameters: TreatCommentsAsGroupSeparators, Include.
19
- # Include: **/*.gemfile, **/Gemfile, **/gems.rb
20
- Bundler/OrderedGems:
17
+ # This cop supports safe autocorrection (--autocorrect).
18
+ # Configuration parameters: Severity, Include.
19
+ # Include: **/*.gemspec
20
+ Gemspec/RequireMFA:
21
21
  Exclude:
22
- - 'Gemfile'
22
+ - 'rmagick.gemspec'
23
23
 
24
24
  # Offense count: 1
25
- # Cop supports --auto-correct.
26
- # Configuration parameters: TreatCommentsAsGroupSeparators, Include.
25
+ # Configuration parameters: Severity, Include.
27
26
  # Include: **/*.gemspec
28
- Gemspec/OrderedDependencies:
27
+ Gemspec/RequiredRubyVersion:
29
28
  Exclude:
30
29
  - 'rmagick.gemspec'
31
30
 
32
- # Offense count: 12
33
- # Cop supports --auto-correct.
31
+ # Offense count: 11
32
+ # This cop supports unsafe autocorrection (--autocorrect-all).
34
33
  # Configuration parameters: Categories, ExpectedOrder.
35
34
  # ExpectedOrder: module_inclusion, constants, public_class_methods, initializer, public_methods, protected_methods, private_methods
36
35
  Layout/ClassStructure:
@@ -42,8 +41,19 @@ Layout/ClassStructure:
42
41
  - 'lib/rvg/pathdata.rb'
43
42
  - 'lib/rvg/rvg.rb'
44
43
 
45
- # Offense count: 2312
46
- # Cop supports --auto-correct.
44
+ # Offense count: 6
45
+ # This cop supports safe autocorrection (--autocorrect).
46
+ # Configuration parameters: AllowMultilineFinalElement.
47
+ Layout/FirstMethodArgumentLineBreak:
48
+ Exclude:
49
+ - 'doc/ex/arcpath.rb'
50
+ - 'doc/ex/evenodd.rb'
51
+ - 'doc/ex/get_type_metrics.rb'
52
+ - 'doc/ex/nonzero.rb'
53
+
54
+ # Offense count: 2311
55
+ # This cop supports safe autocorrection (--autocorrect).
56
+ # Configuration parameters: AllowMultilineFinalElement.
47
57
  Layout/MultilineArrayLineBreaks:
48
58
  Exclude:
49
59
  - 'doc/ex/add_noise.rb'
@@ -56,7 +66,8 @@ Layout/MultilineArrayLineBreaks:
56
66
  - 'lib/rvg/stylable.rb'
57
67
 
58
68
  # Offense count: 192
59
- # Cop supports --auto-correct.
69
+ # This cop supports safe autocorrection (--autocorrect).
70
+ # Configuration parameters: AllowMultilineFinalElement.
60
71
  Layout/MultilineMethodArgumentLineBreaks:
61
72
  Exclude:
62
73
  - 'doc/ex/axes.rb'
@@ -70,25 +81,103 @@ Layout/MultilineMethodArgumentLineBreaks:
70
81
  - 'examples/vignette.rb'
71
82
  - 'lib/rmagick_internal.rb'
72
83
 
84
+ # Offense count: 66
85
+ # This cop supports safe autocorrection (--autocorrect).
86
+ # Configuration parameters: InspectBlocks.
87
+ Layout/RedundantLineBreak:
88
+ Enabled: false
89
+
90
+ # Offense count: 1905
91
+ # This cop supports safe autocorrection (--autocorrect).
92
+ Layout/SingleLineBlockChain:
93
+ Enabled: false
94
+
73
95
  # Offense count: 1
74
- # Cop supports --auto-correct.
75
- # Configuration parameters: AllowForAlignment, EnforcedStyleForExponentOperator.
96
+ # This cop supports safe autocorrection (--autocorrect).
97
+ # Configuration parameters: AllowForAlignment, EnforcedStyleForExponentOperator, EnforcedStyleForRationalLiterals.
76
98
  # SupportedStylesForExponentOperator: space, no_space
99
+ # SupportedStylesForRationalLiterals: space, no_space
77
100
  Layout/SpaceAroundOperators:
78
101
  Exclude:
79
- - 'rmagick.gemspec'
102
+ - 'lib/rvg/misc.rb'
103
+
104
+ # Offense count: 1
105
+ # This cop supports safe autocorrection (--autocorrect).
106
+ Layout/SpaceBeforeBrackets:
107
+ Exclude:
108
+ - 'lib/rmagick_internal.rb'
109
+
110
+ # Offense count: 39
111
+ # This cop supports safe autocorrection (--autocorrect).
112
+ Lint/AmbiguousOperatorPrecedence:
113
+ Exclude:
114
+ - 'doc/ex/coalesce.rb'
115
+ - 'doc/ex/get_type_metrics.rb'
116
+ - 'doc/ex/rvg_clippath.rb'
117
+ - 'doc/ex/skewx.rb'
118
+ - 'examples/histogram.rb'
119
+ - 'examples/vignette.rb'
120
+ - 'lib/rmagick_internal.rb'
121
+ - 'lib/rvg/embellishable.rb'
122
+ - 'lib/rvg/misc.rb'
123
+ - 'lib/rvg/stretchable.rb'
124
+
125
+ # Offense count: 1
126
+ Lint/BinaryOperatorWithIdenticalOperands:
127
+ Exclude:
128
+ - 'spec/rmagick/enum/case_equality_spec.rb'
129
+
130
+ # Offense count: 2
131
+ # Configuration parameters: AllowedMethods.
132
+ # AllowedMethods: enums
133
+ Lint/ConstantDefinitionInBlock:
134
+ Exclude:
135
+ - 'Rakefile'
136
+
137
+ # Offense count: 5517
138
+ # Configuration parameters: Only, Ignore.
139
+ Lint/ConstantResolution:
140
+ Enabled: false
141
+
142
+ # Offense count: 3
143
+ # Configuration parameters: IgnoreLiteralBranches, IgnoreConstantBranches.
144
+ Lint/DuplicateBranch:
145
+ Exclude:
146
+ - 'lib/rvg/embellishable.rb'
147
+ - 'lib/rvg/misc.rb'
148
+
149
+ # Offense count: 8
150
+ # Configuration parameters: AllowComments, AllowEmptyLambdas.
151
+ Lint/EmptyBlock:
152
+ Exclude:
153
+ - 'spec/rmagick/draw/pattern_spec.rb'
154
+ - 'spec/rmagick/image/change_geometry_spec.rb'
155
+ - 'spec/rmagick/image/each_profile_spec.rb'
156
+
157
+ # Offense count: 1
158
+ # Configuration parameters: AllowComments.
159
+ Lint/EmptyFile:
160
+ Exclude:
161
+ - 'spec/rmagick/image/info/view_spec.rb'
80
162
 
81
163
  # Offense count: 1
164
+ # Configuration parameters: AllowComments.
82
165
  Lint/EmptyWhen:
83
166
  Exclude:
84
167
  - 'lib/rvg/misc.rb'
85
168
 
86
- # Offense count: 94
87
- # Cop supports --auto-correct.
169
+ # Offense count: 2
170
+ Lint/FloatComparison:
171
+ Exclude:
172
+ - 'lib/rvg/stretchable.rb'
173
+
174
+ # Offense count: 91
175
+ # This cop supports unsafe autocorrection (--autocorrect-all).
176
+ # Configuration parameters: AllowedMethods, AllowedPatterns, IgnoredClasses.
177
+ # IgnoredClasses: Time, DateTime
88
178
  Lint/NumberConversion:
89
179
  Exclude:
90
180
  - 'doc/ex/get_pixels.rb'
91
- - 'doc/ex/stegano.rb'
92
181
  - 'examples/describe.rb'
93
182
  - 'examples/thumbnail.rb'
94
183
  - 'lib/rmagick_internal.rb'
@@ -99,36 +188,19 @@ Lint/NumberConversion:
99
188
  - 'spec/rmagick/enum/to_i_spec.rb'
100
189
  - 'spec/rmagick/image/export_pixels_spec.rb'
101
190
 
102
- # Offense count: 2
103
- # Cop supports --auto-correct.
104
- Lint/RedundantStringCoercion:
105
- Exclude:
106
- - 'spec/rmagick/font/initialize_spec.rb'
107
-
108
191
  # Offense count: 1
109
192
  Lint/RescueException:
110
193
  Exclude:
111
194
  - 'lib/rmagick_internal.rb'
112
195
 
113
- # Offense count: 1
114
- # Configuration parameters: AllowComments.
115
- Lint/SuppressedException:
116
- Exclude:
117
- - 'lib/rmagick_internal.rb'
118
-
119
- # Offense count: 1
120
- Lint/UselessComparison:
121
- Exclude:
122
- - 'spec/rmagick/enum/case_equality_spec.rb'
123
-
124
- # Offense count: 45
125
- # Configuration parameters: IgnoredMethods.
196
+ # Offense count: 39
197
+ # Configuration parameters: AllowedMethods, AllowedPatterns, CountRepeatedAttributes.
126
198
  Metrics/AbcSize:
127
199
  Max: 537
128
200
 
129
- # Offense count: 77
130
- # Configuration parameters: CountComments, ExcludedMethods.
131
- # ExcludedMethods: refine
201
+ # Offense count: 18
202
+ # Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns, inherit_mode.
203
+ # AllowedMethods: refine
132
204
  Metrics/BlockLength:
133
205
  Max: 155
134
206
 
@@ -138,29 +210,36 @@ Metrics/BlockNesting:
138
210
  Max: 4
139
211
 
140
212
  # Offense count: 9
141
- # Configuration parameters: CountComments.
213
+ # Configuration parameters: CountComments, CountAsOne.
142
214
  Metrics/ClassLength:
143
- Max: 469
215
+ Max: 500
216
+
217
+ # Offense count: 1
218
+ # Configuration parameters: LengthThreshold.
219
+ Metrics/CollectionLiteralLength:
220
+ Exclude:
221
+ - 'doc/ex/smile.rb'
144
222
 
145
- # Offense count: 21
146
- # Configuration parameters: IgnoredMethods.
223
+ # Offense count: 17
224
+ # Configuration parameters: AllowedMethods, AllowedPatterns.
147
225
  Metrics/CyclomaticComplexity:
148
- Max: 42
226
+ Max: 44
149
227
 
150
- # Offense count: 55
151
- # Configuration parameters: CountComments, ExcludedMethods.
228
+ # Offense count: 58
229
+ # Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns.
152
230
  Metrics/MethodLength:
153
231
  Max: 146
154
232
 
155
- # Offense count: 14
233
+ # Offense count: 23
156
234
  # Configuration parameters: CountKeywordArgs.
157
235
  Metrics/ParameterLists:
236
+ MaxOptionalParameters: 5
158
237
  Max: 8
159
238
 
160
- # Offense count: 15
161
- # Configuration parameters: IgnoredMethods.
239
+ # Offense count: 13
240
+ # Configuration parameters: AllowedMethods, AllowedPatterns.
162
241
  Metrics/PerceivedComplexity:
163
- Max: 40
242
+ Max: 42
164
243
 
165
244
  # Offense count: 4
166
245
  Naming/AccessorMethodName:
@@ -169,68 +248,79 @@ Naming/AccessorMethodName:
169
248
  - 'lib/rvg/misc.rb'
170
249
 
171
250
  # Offense count: 2
251
+ # Configuration parameters: AllowedNames.
252
+ # AllowedNames: module_parent
172
253
  Naming/ClassAndModuleCamelCase:
173
254
  Exclude:
174
255
  - 'lib/rmagick_internal.rb'
175
256
 
176
- # Offense count: 120
177
- Naming/ConstantName:
178
- Exclude:
179
- - 'doc/ex/arcs02.rb'
180
- - 'doc/ex/cubic01.rb'
181
- - 'doc/ex/cubic02.rb'
182
- - 'doc/ex/drop_shadow.rb'
183
- - 'doc/ex/flatten_images.rb'
184
- - 'doc/ex/get_type_metrics.rb'
185
- - 'doc/ex/gradientfill.rb'
186
- - 'doc/ex/hatchfill.rb'
187
- - 'doc/ex/rubyname.rb'
188
- - 'doc/ex/smile.rb'
189
- - 'doc/ex/tref01.rb'
190
- - 'examples/demo.rb'
191
- - 'lib/rmagick_internal.rb'
192
-
193
- # Offense count: 12
194
- # Configuration parameters: ExpectMatchingDefinition, Regex, IgnoreExecutableScripts, AllowedAcronyms.
195
- # AllowedAcronyms: CLI, DSL, ACL, API, ASCII, CPU, CSS, DNS, EOF, GUID, HTML, HTTP, HTTPS, ID, IP, JSON, LHS, QPS, RAM, RHS, RPC, SLA, SMTP, SQL, SSH, TCP, TLS, TTL, UDP, UI, UID, UUID, URI, URL, UTF8, VM, XML, XMPP, XSRF, XSS
196
- Naming/FileName:
197
- Exclude:
198
- - 'doc/ex/InitialCoords.rb'
199
- - 'doc/ex/NewCoordSys.rb'
200
- - 'doc/ex/OrigCoordSys.rb'
201
- - 'doc/ex/PreserveAspectRatio.rb'
202
- - 'doc/ex/RotateScale.rb'
203
- - 'doc/ex/Skew.rb'
204
- - 'doc/ex/Use01.rb'
205
- - 'doc/ex/Use02.rb'
206
- - 'doc/ex/Use03.rb'
207
- - 'doc/ex/ViewBox.rb'
208
- - 'doc/ex/quantize-m.rb'
209
-
210
257
  # Offense count: 4
211
- # Configuration parameters: EnforcedStyle, IgnoredPatterns.
258
+ # Configuration parameters: EnforcedStyle, AllowedPatterns.
212
259
  # SupportedStyles: snake_case, camelCase
213
260
  Naming/MethodName:
214
261
  Exclude:
215
262
  - 'lib/rvg/misc.rb'
216
263
  - 'lib/rvg/transformable.rb'
217
264
 
218
- # Offense count: 222
265
+ # Offense count: 220
219
266
  # Configuration parameters: MinNameLength, AllowNamesEndingInNumbers, AllowedNames, ForbiddenNames.
220
- # AllowedNames: io, id, to, by, on, in, at, ip, db, os, pp
267
+ # AllowedNames: as, at, by, cc, db, id, if, in, io, ip, of, on, os, pp, to
221
268
  Naming/MethodParameterName:
222
- Enabled: false
269
+ Exclude:
270
+ - 'doc/ex/get_type_metrics.rb'
271
+ - 'examples/histogram.rb'
272
+ - 'lib/rmagick_internal.rb'
273
+ - 'lib/rvg/clippath.rb'
274
+ - 'lib/rvg/container.rb'
275
+ - 'lib/rvg/embellishable.rb'
276
+ - 'lib/rvg/misc.rb'
277
+ - 'lib/rvg/paint.rb'
278
+ - 'lib/rvg/pathdata.rb'
279
+ - 'lib/rvg/rvg.rb'
280
+ - 'lib/rvg/stretchable.rb'
281
+ - 'lib/rvg/stylable.rb'
282
+ - 'lib/rvg/text.rb'
283
+ - 'lib/rvg/transformable.rb'
284
+ - 'lib/rvg/units.rb'
223
285
 
224
- # Offense count: 421
225
- # Configuration parameters: Max.
286
+ # Offense count: 428
287
+ # Configuration parameters: CountAsOne.
226
288
  RSpec/ExampleLength:
289
+ Max: 126
290
+
291
+ # Offense count: 538
292
+ # This cop supports safe autocorrection (--autocorrect).
293
+ # Configuration parameters: CustomTransform, IgnoredWords, DisallowedExamples.
294
+ # DisallowedExamples: works
295
+ RSpec/ExampleWording:
227
296
  Enabled: false
228
297
 
229
- # Offense count: 539
230
- # Configuration parameters: AggregateFailuresByDefault.
298
+ # Offense count: 1
299
+ # Configuration parameters: Include, CustomTransform, IgnoreMethods, SpecSuffixOnly.
300
+ # Include: **/*_spec*rb*, **/spec/**/*
301
+ RSpec/FilePath:
302
+ Exclude:
303
+ - 'spec/magick_spec.rb'
304
+
305
+ # Offense count: 1
306
+ RSpec/IdenticalEqualityAssertion:
307
+ Exclude:
308
+ - 'spec/rmagick/image/spaceship_spec.rb'
309
+
310
+ # Offense count: 543
231
311
  RSpec/MultipleExpectations:
232
312
  Max: 72
233
313
 
314
+ # Offense count: 4
315
+ # Configuration parameters: AllowedPatterns.
316
+ # AllowedPatterns: ^expect_, ^assert_
317
+ RSpec/NoExpectationExample:
318
+ Exclude:
319
+ - 'spec/rmagick/image/destroy_bang_spec.rb'
320
+ - 'spec/rmagick/image/export_pixels_spec.rb'
321
+ - 'spec/rmagick/image/import_pixels_spec.rb'
322
+ - 'spec/rmagick/image_list/write_spec.rb'
323
+
234
324
  # Offense count: 4
235
325
  Security/MarshalLoad:
236
326
  Exclude:
@@ -239,18 +329,56 @@ Security/MarshalLoad:
239
329
  - 'spec/rmagick/image/marshal_spec.rb'
240
330
  - 'spec/rmagick/image_list/marshal_spec.rb'
241
331
 
332
+ # Offense count: 6
333
+ # This cop supports safe autocorrection (--autocorrect).
334
+ # Configuration parameters: AllowOnlyRestArgument, UseAnonymousForwarding, RedundantRestArgumentNames, RedundantKeywordRestArgumentNames, RedundantBlockArgumentNames.
335
+ # RedundantRestArgumentNames: args, arguments
336
+ # RedundantKeywordRestArgumentNames: kwargs, options, opts
337
+ # RedundantBlockArgumentNames: blk, block, proc
338
+ Style/ArgumentsForwarding:
339
+ Exclude:
340
+ - 'lib/rmagick_internal.rb'
341
+ - 'lib/rvg/misc.rb'
342
+
343
+ # Offense count: 153
344
+ # This cop supports unsafe autocorrection (--autocorrect-all).
345
+ Style/ArrayFirstLast:
346
+ Enabled: false
347
+
242
348
  # Offense count: 7
349
+ # This cop supports safe autocorrection (--autocorrect).
350
+ # Configuration parameters: AllowOnConstant, AllowOnSelfClass.
243
351
  Style/CaseEquality:
244
352
  Exclude:
245
353
  - 'spec/rmagick/enum/case_equality_spec.rb'
246
354
  - 'spec/rmagick/pixel/dup_spec.rb'
247
355
  - 'spec/rmagick/pixel/threequals_spec.rb'
248
356
 
249
- # Offense count: 89
357
+ # Offense count: 2
358
+ # This cop supports unsafe autocorrection (--autocorrect-all).
359
+ # Configuration parameters: AllowedMethods, AllowedPatterns.
360
+ # AllowedMethods: ==, equal?, eql?
361
+ Style/ClassEqualityComparison:
362
+ Exclude:
363
+ - 'spec/rmagick/image_list/all_predicate_spec.rb'
364
+ - 'spec/rmagick/image_list/any_predicate_spec.rb'
365
+
366
+ # Offense count: 2
367
+ # This cop supports safe autocorrection (--autocorrect).
368
+ # Configuration parameters: EnforcedStyle.
369
+ # SupportedStyles: def_self, self_class
370
+ Style/ClassMethodsDefinitions:
371
+ Exclude:
372
+ - 'lib/rmagick_internal.rb'
373
+ - 'lib/rvg/units.rb'
374
+
375
+ # Offense count: 88
376
+ # This cop supports unsafe autocorrection (--autocorrect-all).
250
377
  Style/CommentedKeyword:
251
378
  Enabled: false
252
379
 
253
- # Offense count: 126
380
+ # Offense count: 129
381
+ # Configuration parameters: IgnoreModules.
254
382
  Style/ConstantVisibility:
255
383
  Exclude:
256
384
  - 'examples/histogram.rb'
@@ -262,65 +390,52 @@ Style/ConstantVisibility:
262
390
  - 'lib/rvg/stylable.rb'
263
391
  - 'spec/support/helpers.rb'
264
392
 
265
- # Offense count: 809
266
- # Cop supports --auto-correct.
267
- # Configuration parameters: Notice, AutocorrectNotice.
268
- Style/Copyright:
269
- Enabled: false
393
+ # Offense count: 3
394
+ Style/DocumentDynamicEvalDefinition:
395
+ Exclude:
396
+ - 'lib/rmagick_internal.rb'
270
397
 
271
- # Offense count: 37
398
+ # Offense count: 36
399
+ # Configuration parameters: AllowedConstants.
272
400
  Style/Documentation:
273
401
  Enabled: false
274
402
 
275
- # Offense count: 72
403
+ # Offense count: 163
276
404
  # Configuration parameters: RequireForNonPublicMethods.
277
405
  Style/DocumentationMethod:
406
+ Enabled: false
407
+
408
+ # Offense count: 4
409
+ # This cop supports safe autocorrection (--autocorrect).
410
+ # Configuration parameters: AllowedVars.
411
+ Style/FetchEnvVar:
278
412
  Exclude:
279
- - 'spec/**/*'
280
- - 'test/**/*'
281
- - 'Rakefile'
282
- - 'doc/ex/ViewBox.rb'
283
- - 'doc/ex/sparse_color.rb'
284
- - 'examples/histogram.rb'
285
- - 'examples/pattern_fill.rb'
286
413
  - 'ext/RMagick/extconf.rb'
287
- - 'lib/rmagick_internal.rb'
288
- - 'lib/rvg/container.rb'
289
- - 'lib/rvg/deep_equal.rb'
290
- - 'lib/rvg/embellishable.rb'
291
- - 'lib/rvg/misc.rb'
292
- - 'lib/rvg/stylable.rb'
293
- - 'lib/rvg/transformable.rb'
294
- - 'lib/rvg/units.rb'
295
414
 
296
- # Offense count: 208
297
- # Configuration parameters: EnforcedStyle.
415
+ # Offense count: 191
416
+ # This cop supports safe autocorrection (--autocorrect).
417
+ # Configuration parameters: MaxUnannotatedPlaceholdersAllowed, AllowedMethods, AllowedPatterns.
298
418
  # SupportedStyles: annotated, template, unannotated
299
419
  Style/FormatStringToken:
300
- Exclude:
301
- - 'doc/ex/colors.rb'
302
- - 'doc/ex/fonts.rb'
303
- - 'doc/ex/implode.rb'
304
- - 'doc/ex/stegano.rb'
305
- - 'examples/identify.rb'
306
- - 'lib/rmagick_internal.rb'
307
- - 'lib/rvg/pathdata.rb'
420
+ EnforcedStyle: unannotated
308
421
 
309
- # Offense count: 808
310
- # Cop supports --auto-correct.
422
+ # Offense count: 802
423
+ # This cop supports unsafe autocorrection (--autocorrect-all).
311
424
  # Configuration parameters: EnforcedStyle.
312
425
  # SupportedStyles: always, always_true, never
313
426
  Style/FrozenStringLiteralComment:
314
427
  Enabled: false
315
428
 
316
- # Offense count: 42
429
+ # Offense count: 46
317
430
  # Configuration parameters: AllowedVariables.
318
431
  Style/GlobalVars:
319
432
  Exclude:
320
433
  - 'ext/RMagick/extconf.rb'
321
434
 
322
435
  # Offense count: 12
323
- # Cop supports --auto-correct.
436
+ # This cop supports unsafe autocorrection (--autocorrect-all).
437
+ # Configuration parameters: AllowedReceivers.
438
+ # AllowedReceivers: Thread.current
324
439
  Style/HashEachMethods:
325
440
  Exclude:
326
441
  - 'doc/ex/preview.rb'
@@ -336,30 +451,37 @@ Style/HashEachMethods:
336
451
  - 'spec/rmagick/image/info/orientation_spec.rb'
337
452
  - 'spec/rmagick/image/info/units_spec.rb'
338
453
 
339
- # Offense count: 6
340
- # Cop supports --auto-correct.
454
+ # Offense count: 4
455
+ # This cop supports safe autocorrection (--autocorrect).
341
456
  Style/IfUnlessModifier:
342
457
  Exclude:
343
458
  - 'ext/RMagick/extconf.rb'
344
459
 
345
- # Offense count: 148
460
+ # Offense count: 146
346
461
  Style/InlineComment:
347
462
  Enabled: false
348
463
 
349
- # Offense count: 4804
350
- # Cop supports --auto-correct.
351
- # Configuration parameters: IgnoreMacros, IgnoredMethods, IgnoredPatterns, IncludedMacros, AllowParenthesesInMultilineCall, AllowParenthesesInChaining, AllowParenthesesInCamelCaseMethod, EnforcedStyle.
464
+ # Offense count: 10
465
+ # This cop supports unsafe autocorrection (--autocorrect-all).
466
+ # Configuration parameters: InverseMethods.
467
+ Style/InvertibleUnlessCondition:
468
+ Exclude:
469
+ - 'doc/ex/get_type_metrics.rb'
470
+ - 'examples/identify.rb'
471
+ - 'ext/RMagick/extconf.rb'
472
+ - 'lib/rmagick_internal.rb'
473
+ - 'lib/rvg/embellishable.rb'
474
+ - 'lib/rvg/stretchable.rb'
475
+
476
+ # Offense count: 4509
477
+ # This cop supports safe autocorrection (--autocorrect).
478
+ # Configuration parameters: IgnoreMacros, AllowedMethods, AllowedPatterns, IncludedMacros, AllowParenthesesInMultilineCall, AllowParenthesesInChaining, AllowParenthesesInCamelCaseMethod, AllowParenthesesInStringInterpolation, EnforcedStyle.
352
479
  # SupportedStyles: require_parentheses, omit_parentheses
353
480
  Style/MethodCallWithArgsParentheses:
354
481
  Enabled: false
355
482
 
356
- # Offense count: 2
357
- Style/MethodMissingSuper:
358
- Exclude:
359
- - 'lib/rmagick_internal.rb'
360
- - 'lib/rvg/misc.rb'
361
-
362
- # Offense count: 64
483
+ # Offense count: 57
484
+ # This cop supports safe autocorrection (--autocorrect).
363
485
  # Configuration parameters: EnforcedStyle.
364
486
  # SupportedStyles: if, case, both
365
487
  Style/MissingElse:
@@ -371,32 +493,16 @@ Style/MissingRespondToMissing:
371
493
  - 'lib/rmagick_internal.rb'
372
494
  - 'lib/rvg/misc.rb'
373
495
 
374
- # Offense count: 12
375
- Style/MixinUsage:
376
- Exclude:
377
- - 'doc/ex/colors.rb'
378
- - 'doc/ex/composite.rb'
379
- - 'doc/ex/crop_with_gravity.rb'
380
- - 'doc/ex/smile.rb'
381
- - 'examples/crop_with_gravity.rb'
382
- - 'examples/demo.rb'
383
- - 'examples/image_opacity.rb'
384
- - 'examples/import_export.rb'
385
- - 'examples/pattern_fill.rb'
386
- - 'examples/rotating_text.rb'
387
- - 'examples/thumbnail.rb'
388
- - 'examples/vignette.rb'
389
-
390
- # Offense count: 152
391
- # Cop supports --auto-correct.
496
+ # Offense count: 59
497
+ # This cop supports unsafe autocorrection (--autocorrect-all).
392
498
  # Configuration parameters: EnforcedStyle.
393
499
  # SupportedStyles: literals, strict
394
500
  Style/MutableConstant:
395
501
  Enabled: false
396
502
 
397
503
  # Offense count: 32
398
- # Cop supports --auto-correct.
399
- # Configuration parameters: AutoCorrect, EnforcedStyle, IgnoredMethods.
504
+ # This cop supports unsafe autocorrection (--autocorrect-all).
505
+ # Configuration parameters: EnforcedStyle, AllowedMethods, AllowedPatterns.
400
506
  # SupportedStyles: predicate, comparison
401
507
  Style/NumericPredicate:
402
508
  Exclude:
@@ -404,36 +510,54 @@ Style/NumericPredicate:
404
510
  - 'lib/rmagick_internal.rb'
405
511
  - 'lib/rvg/embellishable.rb'
406
512
 
407
- # Offense count: 1
408
- # Cop supports --auto-correct.
409
- # Configuration parameters: AllowMultipleReturnValues.
410
- Style/RedundantReturn:
513
+ # Offense count: 4
514
+ # Configuration parameters: AllowedMethods.
515
+ # AllowedMethods: respond_to_missing?
516
+ Style/OptionalBooleanParameter:
411
517
  Exclude:
412
- - 'examples/histogram.rb'
518
+ - 'doc/ex/sparse_color.rb'
519
+ - 'lib/rmagick_internal.rb'
520
+ - 'lib/rvg/pathdata.rb'
413
521
 
414
- # Offense count: 3
415
- # Cop supports --auto-correct.
416
- # Configuration parameters: ConvertCodeThatCanStartToReturnNil, AllowedMethods.
417
- # AllowedMethods: present?, blank?, presence, try, try!
418
- Style/SafeNavigation:
522
+ # Offense count: 16
523
+ # This cop supports safe autocorrection (--autocorrect).
524
+ # Configuration parameters: .
525
+ # SupportedStyles: same_as_string_literals, single_quotes, double_quotes
526
+ Style/QuotedSymbols:
527
+ EnforcedStyle: double_quotes
528
+
529
+ # Offense count: 1
530
+ # This cop supports safe autocorrection (--autocorrect).
531
+ Style/RedundantBegin:
419
532
  Exclude:
420
- - 'lib/rmagick_internal.rb'
533
+ - 'lib/rvg/stylable.rb'
421
534
 
422
- # Offense count: 5
423
- Style/Send:
535
+ # Offense count: 19
536
+ # This cop supports unsafe autocorrection (--autocorrect-all).
537
+ Style/RequireOrder:
424
538
  Exclude:
539
+ - 'Rakefile'
540
+ - 'doc/ex/polaroid.rb'
541
+ - 'ext/RMagick/extconf.rb'
425
542
  - 'lib/rmagick_internal.rb'
426
- - 'spec/rmagick/image/destroy_spec.rb'
543
+ - 'lib/rvg/rvg.rb'
544
+ - 'rmagick.gemspec'
545
+ - 'spec/spec_helper.rb'
427
546
 
428
- # Offense count: 2
429
- # Configuration parameters: Methods.
430
- # Methods: {"reduce"=>["acc", "elem"]}, {"inject"=>["acc", "elem"]}
431
- Style/SingleLineBlockParams:
547
+ # Offense count: 1
548
+ # This cop supports unsafe autocorrection (--autocorrect-all).
549
+ Style/StaticClass:
432
550
  Exclude:
433
- - 'lib/rvg/misc.rb'
551
+ - 'spec/rmagick/draw/class_methods/_dummy_img__spec.rb'
434
552
 
435
- # Offense count: 20
436
- # Cop supports --auto-correct.
553
+ # Offense count: 185
554
+ # This cop supports unsafe autocorrection (--autocorrect-all).
555
+ # Configuration parameters: Mode.
556
+ Style/StringConcatenation:
557
+ Enabled: false
558
+
559
+ # Offense count: 18
560
+ # This cop supports unsafe autocorrection (--autocorrect-all).
437
561
  Style/StringHashKeys:
438
562
  Exclude:
439
563
  - 'Rakefile'
@@ -441,16 +565,31 @@ Style/StringHashKeys:
441
565
  - 'lib/rvg/misc.rb'
442
566
  - 'spec/rmagick/image/properties_spec.rb'
443
567
 
444
- # Offense count: 226
445
- # Cop supports --auto-correct.
568
+ # Offense count: 233
569
+ # This cop supports safe autocorrection (--autocorrect).
446
570
  # Configuration parameters: EnforcedStyle, ConsistentQuotesInMultiline.
447
571
  # SupportedStyles: single_quotes, double_quotes
448
572
  Style/StringLiterals:
449
573
  Enabled: false
450
574
 
451
- # Offense count: 975
452
- # Cop supports --auto-correct.
453
- # Configuration parameters: AutoCorrect, AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns.
575
+ # Offense count: 1
576
+ # This cop supports unsafe autocorrection (--autocorrect-all).
577
+ # Configuration parameters: EnforcedStyle.
578
+ # SupportedStyles: forbid_for_all_comparison_operators, forbid_for_equality_operators_only, require_for_all_comparison_operators, require_for_equality_operators_only
579
+ Style/YodaCondition:
580
+ Exclude:
581
+ - 'spec/rmagick/image/destroy_spec.rb'
582
+
583
+ # Offense count: 110
584
+ # This cop supports unsafe autocorrection (--autocorrect-all).
585
+ # Configuration parameters: .
586
+ # SupportedOperators: *, +, &, |, ^
587
+ Style/YodaExpression:
588
+ Enabled: false
589
+
590
+ # Offense count: 135
591
+ # This cop supports safe autocorrection (--autocorrect).
592
+ # Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, AllowedPatterns.
454
593
  # URISchemes: http, https
455
594
  Layout/LineLength:
456
595
  Max: 217