diff --git a/CHANGELOG.md b/CHANGELOG.md index 4a9a3f77..f090e6f2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,8 @@ ## Master +- Add `.xctestplan` extension to available file extensions [@gsl-anthonymerle][] - [#653](https://github.com/danger/swift/pull/653) + ## 3.21.2 - Fix Runner's path resolution to enable `--cwd` with relative paths [@Fab1n](https://github.com/Fab1n) - [#650](https://github.com/danger/swift/pull/650) @@ -622,4 +624,5 @@ This release also includes: [@aserdobintsev]: https://github.com/aserdobintsev [@dromerobarria]: https://github.com/dromerobarria [@msnazarow]: https://github.com/msnazarow -[@Davarg]https://github.com/Davarg +[@Davarg]: https://github.com/Davarg +[@gsl-anthonymerle]: https://github.com/gsl-anthonymerle diff --git a/Sources/Danger/File.swift b/Sources/Danger/File.swift index 733e98ec..67740898 100644 --- a/Sources/Danger/File.swift +++ b/Sources/Danger/File.swift @@ -19,7 +19,7 @@ public extension File { public enum FileType: String, Equatable, CaseIterable { // swiftlint:disable:next identifier_name - case h, json, m, markdown = "md", mm, pbxproj, plist, storyboard, swift, xcscheme, yaml, yml + case h, json, m, markdown = "md", mm, pbxproj, plist, storyboard, swift, xcscheme, yaml, yml, xctestplan } // MARK: - FileType extensions diff --git a/Tests/DangerTests/FileTests.swift b/Tests/DangerTests/FileTests.swift index b58f5fed..788e7880 100644 --- a/Tests/DangerTests/FileTests.swift +++ b/Tests/DangerTests/FileTests.swift @@ -129,4 +129,12 @@ final class FileTests: XCTestCase { XCTAssertEqual(file.fileType, expectedType) } + + func test_fileType_forXCTestPlan() { + let file: File = "TestPlan.xctestplan" + + let expectedType: FileType = .xctestplan + + XCTAssertEqual(file.fileType, expectedType) + } }