-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.rubocop.yml
More file actions
201 lines (152 loc) · 3.6 KB
/
.rubocop.yml
File metadata and controls
201 lines (152 loc) · 3.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
require:
- rubocop-rspec
AllCops:
TargetRubyVersion: 3.0
NewCops: enable
SuggestExtensions: false
Exclude:
- 'vendor/**/*'
- 'tmp/**/*'
- 'examples/**/*' # Examples are meant to be simple scripts
- 'test_basic.rb' # Simple test script
Style/Documentation:
Enabled: false
# Examples use top-level include for readability
Style/MixinUsage:
Exclude:
- 'examples/**/*'
# Metrics settings
Metrics/BlockLength:
Max: 40
Exclude:
- 'spec/**/*'
- '*.gemspec'
Metrics/MethodLength:
Max: 80
Exclude:
- 'examples/**/*'
Metrics/ClassLength:
Max: 500
Metrics/AbcSize:
Max: 70
Exclude:
- 'examples/**/*'
Metrics/CyclomaticComplexity:
Max: 35
Metrics/PerceivedComplexity:
Max: 40
# Some API methods need many parameters to match the API
Metrics/ParameterLists:
Max: 8
CountKeywordArgs: false
Layout/LineLength:
Max: 160
Exclude:
- 'spec/**/*'
# API method names follow Conductor/Orkes API conventions
Naming/AccessorMethodName:
Enabled: false
# Short parameter names are acceptable for callbacks
Naming/MethodParameterName:
MinNameLength: 1
# Script permissions are not relevant for gem distribution
Lint/ScriptPermission:
Enabled: false
# Variable naming in tests (e.g., task_def_1, task_def_2)
Naming/VariableNumber:
Exclude:
- 'spec/**/*'
# Allow shadowing in rspec blocks for error handling
Lint/ShadowingOuterLocalVariable:
Exclude:
- 'spec/**/*'
# Allow constant definition in rspec blocks for test helpers
Lint/ConstantDefinitionInBlock:
Exclude:
- 'spec/**/*'
# Model classes use attribute accessors instead of super
Lint/MissingSuper:
Exclude:
- 'lib/conductor/http/models/**/*'
- 'lib/conductor/workflow/**/*'
- 'lib/conductor/orkes/models/**/*'
# Predicate methods may have is_ prefix to match API conventions
Naming/PredicateName:
Enabled: false
# Unused assignments in rescue blocks are intentional
Lint/UselessAssignment:
Exclude:
- 'lib/**/*'
# Unused arguments in overridable methods are intentional
Lint/UnusedMethodArgument:
Enabled: false
# Duplicate branches are acceptable in case statements for clarity
Lint/DuplicateBranch:
Enabled: false
# Module-level method visibility is intentional
Lint/IneffectiveAccessModifier:
Enabled: false
# Early returns in iterators are intentional
Lint/NonLocalExitFromIterator:
Enabled: false
# Some methods return nil in rescue blocks intentionally
Lint/NoReturnInBeginEndBlocks:
Enabled: false
# RSpec configuration
RSpec/ExampleLength:
Max: 100
Exclude:
- 'spec/integration/**/*'
RSpec/MultipleExpectations:
Max: 20
Exclude:
- 'spec/integration/**/*'
RSpec/NestedGroups:
Max: 6
RSpec/MultipleMemoizedHelpers:
Max: 20
RSpec/InstanceVariable:
Exclude:
- 'spec/integration/**/*'
RSpec/LetSetup:
Enabled: false
RSpec/DescribeClass:
Enabled: false
RSpec/ContextWording:
Enabled: false
RSpec/MessageSpies:
Enabled: false
RSpec/StubbedMock:
Enabled: false
RSpec/AnyInstance:
Enabled: false
RSpec/BeforeAfterAll:
Exclude:
- 'spec/integration/**/*'
RSpec/ExpectActual:
Exclude:
- 'spec/integration/**/*'
RSpec/IdenticalEqualityAssertion:
Exclude:
- 'spec/integration/**/*'
RSpec/RepeatedExample:
Enabled: false
RSpec/RepeatedExampleGroupBody:
Enabled: false
RSpec/RepeatedExampleGroupDescription:
Enabled: false
RSpec/IndexedLet:
Enabled: false
RSpec/IteratedExpectation:
Enabled: false
RSpec/LeakyConstantDeclaration:
Exclude:
- 'spec/integration/**/*'
RSpec/BeEq:
Enabled: false
RSpec/MultipleDescribes:
Enabled: false
RSpec/FilePath:
Enabled: false
RSpec/VerifiedDoubles:
Enabled: false