mirror of
https://github.com/realm/SwiftLint.git
synced 2026-05-07 20:12:49 +00:00
16 lines
580 B
Swift
16 lines
580 B
Swift
@AutoConfigParser
|
|
struct NoMagicNumbersConfiguration: SeverityBasedRuleConfiguration {
|
|
@ConfigurationElement(key: "severity")
|
|
private(set) var severityConfiguration = SeverityConfiguration<Parent>(.warning)
|
|
@ConfigurationElement(
|
|
key: "test_parent_classes",
|
|
postprocessor: { $0.formUnion(["QuickSpec", "XCTestCase"]) }
|
|
)
|
|
private(set) var testParentClasses = Set<String>()
|
|
@ConfigurationElement(
|
|
key: "allowed_numbers",
|
|
postprocessor: { $0.formUnion([0, 1, 100]) }
|
|
)
|
|
private(set) var allowedNumbers = Set<Double>()
|
|
}
|