Skip to content

Commit 9c856ba

Browse files
committed
fix: fix Rubocop Metrics/BlockLength offense
Ignore this offense for the gemspec and for tests since the DSL for both make it hard to limit the block length.
1 parent 54c4a3b commit 9c856ba

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

.rubocop.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,12 @@ inherit_from: .rubocop_todo.yml
33
inherit_gem:
44
main_branch_shared_rubocop_config: config/rubocop.yml
55

6+
Metrics/BlockLength:
7+
Exclude:
8+
- "tests/test_helper.rb"
9+
- "tests/units/**/*"
10+
- "*.gemspec"
11+
612
AllCops:
713
# Pin this project to Ruby 3.1 in case the shared config above is upgraded to 3.2
814
# or later.

.rubocop_todo.yml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,6 @@
1111
Metrics/AbcSize:
1212
Max: 109
1313

14-
# Offense count: 8
15-
# Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns.
16-
# AllowedMethods: refine
17-
Metrics/BlockLength:
18-
Max: 49
19-
2014
# Offense count: 21
2115
# Configuration parameters: CountComments, CountAsOne.
2216
Metrics/ClassLength:

0 commit comments

Comments
 (0)