Skip to content

Commit c7a611a

Browse files
committed
Add configuration option OnlyStaticConstants to RSpec/DescribedClass
Fix: rubocop/rubocop-rspec#1741 (comment) Fix: rubocop/rubocop-rspec#1741 (comment)
1 parent a9761e2 commit c7a611a

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
## Master (Unreleased)
44

55
- Fix a false positive for `RSpec/RepeatedSubjectCall` when `subject.method_call`. ([@ydah])
6+
- Add configuration option `OnlyStaticConstants` to `RSpec/DescribedClass`. ([@ydah])
67

78
## 2.27.0 (2024-03-01)
89

config/default.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -283,9 +283,10 @@ RSpec/DescribedClass:
283283
SupportedStyles:
284284
- described_class
285285
- explicit
286+
OnlyStaticConstants: true
286287
SafeAutoCorrect: false
287288
VersionAdded: '1.0'
288-
VersionChanged: '1.11'
289+
VersionChanged: "<<next>>"
289290
Reference: https://www.rubydoc.info/gems/rubocop-rspec/RuboCop/Cop/RSpec/DescribedClass
290291

291292
RSpec/DescribedClassModuleWrapping:

0 commit comments

Comments
 (0)