mirror of
https://github.com/realm/SwiftLint.git
synced 2026-06-06 20:18:40 +00:00
Add MARKs
to trigger a new build.
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
import SourceKittenFramework
|
||||
|
||||
public struct RequiredXCTestTearDownRule: Rule, OptInRule, ConfigurationProviderRule, AutomaticTestableRule {
|
||||
// MARK: - Properties
|
||||
|
||||
public var configuration = SeverityConfiguration(.warning)
|
||||
|
||||
public static let description = RuleDescription(
|
||||
@@ -85,12 +87,18 @@ public struct RequiredXCTestTearDownRule: Rule, OptInRule, ConfigurationProvider
|
||||
]
|
||||
)
|
||||
|
||||
// MARK: - Life cycle
|
||||
|
||||
public init() {}
|
||||
|
||||
// MARK: - Public
|
||||
|
||||
public func validate(file: SwiftLintFile) -> [StyleViolation] {
|
||||
testClasses(in: file).compactMap { violations(in: file, for: $0) }
|
||||
}
|
||||
|
||||
// MARK: - Private
|
||||
|
||||
private func testClasses(in file: SwiftLintFile) -> [SourceKittenDictionary] {
|
||||
file.structureDictionary.substructure.filter { dictionary in
|
||||
guard dictionary.declarationKind == .class else { return false }
|
||||
|
||||
Reference in New Issue
Block a user