mirror of
https://github.com/realm/SwiftLint.git
synced 2026-06-06 20:18:40 +00:00
Add test for directories with a '.swift' suffix being treated as files.
This commit is contained in:
committed by
Marcelo Fabri
parent
0a4b562452
commit
0920b4bbef
@@ -180,6 +180,20 @@ class ConfigurationTests: XCTestCase {
|
||||
XCTAssertEqual(["directory/File1.swift", "directory/File2.swift"], paths)
|
||||
}
|
||||
|
||||
func testLintablePaths() {
|
||||
let paths = Configuration().lintablePaths(inPath: projectMockPathLevel0)
|
||||
let filenames = paths.map { $0.bridge().lastPathComponent }
|
||||
let expectedFilenames = [
|
||||
"DirectoryLevel1.swift",
|
||||
"Level0.swift",
|
||||
"Level1.swift",
|
||||
"Level3.swift",
|
||||
"Level2.swift"
|
||||
]
|
||||
|
||||
XCTAssertEqual(expectedFilenames, filenames)
|
||||
}
|
||||
|
||||
// MARK: - Testing Configuration Equality
|
||||
|
||||
func testIsEqualTo() {
|
||||
|
||||
+1
@@ -0,0 +1 @@
|
||||
// This is just a mock Swift file
|
||||
Reference in New Issue
Block a user