Enable SwiftLint rule 'strict_fileprivate' and fix all violations

This commit is contained in:
Danny Moesch 2020-07-05 23:09:10 +02:00 committed by Mingshen Sun
parent 67301d64d3
commit 79dbac4e9e
2 changed files with 3 additions and 3 deletions

View file

@ -155,7 +155,7 @@ whitelist_rules:
# - sorted_imports # Managed by SwiftFormat. # - sorted_imports # Managed by SwiftFormat.
- statement_position - statement_position
# - static_operator # - static_operator
# - strict_fileprivate - strict_fileprivate
- strong_iboutlet - strong_iboutlet
- superfluous_disable_command - superfluous_disable_command
- switch_case_alignment - switch_case_alignment

View file

@ -11,14 +11,14 @@ import XCTest
@testable import passKit @testable import passKit
struct PGPTestSet { struct PGPTestSet {
fileprivate static var ALL_TEST_SETS: [String: PGPTestSet] = [:] fileprivate static var ALL_TEST_SETS: [String: PGPTestSet] = [:] // swiftlint:disable:this strict_fileprivate
let publicKey: String let publicKey: String
let privateKey: String let privateKey: String
let fingerprint: String let fingerprint: String
let passphrase: String let passphrase: String
fileprivate func collect() -> Self { fileprivate func collect() -> Self { // swiftlint:disable:this strict_fileprivate
Self.ALL_TEST_SETS[fingerprint] = self Self.ALL_TEST_SETS[fingerprint] = self
return self return self
} }