Skip to content

Commit f3b0845

Browse files
Disable incremental test suite on windows
1 parent d9111cf commit f3b0845

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

Tests/SwiftDriverTests/IncrementalCompilationTests.swift

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,9 @@ final class IncrementalCompilationTests: XCTestCase {
116116
}
117117
var extraExplicitBuildArgs: [String] = []
118118

119-
override func setUp() {
119+
override func setUpWithError() throws {
120+
try super.setUpWithError()
121+
120122
self.tempDir = try! withTemporaryDirectory(removeTreeOnDeinit: false) {$0}
121123
try! localFileSystem.createDirectory(explicitModuleCacheDir)
122124
try! localFileSystem.createDirectory(derivedDataPath)
@@ -154,6 +156,9 @@ final class IncrementalCompilationTests: XCTestCase {
154156
if driver.isFrontendArgSupported(.moduleLoadMode) {
155157
self.extraExplicitBuildArgs = ["-Xfrontend", "-module-load-mode", "-Xfrontend", "prefer-interface"]
156158
}
159+
160+
// Disable incremental tests on windows due to very different module setup.
161+
try XCTSkipIf(driver.targetTriple.isWindows, "https://github.com/swiftlang/swift-driver/issues/2029")
157162
}
158163

159164
deinit {
@@ -360,7 +365,7 @@ extension IncrementalCompilationTests {
360365
XCTAssertFalse(mandatoryJobInputs.contains("other.swift"))
361366
}
362367

363-
// External deps timestamp updated but contents are the same, and file-hashing is explicitly disabled
368+
// External deps timestamp updated but contents are the same, and file-hashing is explicitly disabled
364369
func testExplicitIncrementalBuildExternalDepsWithoutHashing() throws {
365370
replace(contentsOf: "other", with: "import E;let bar = foo")
366371
try buildInitialState(extraArguments: ["-disable-incremental-file-hashing"], explicitModuleBuild: true)
@@ -372,7 +377,7 @@ extension IncrementalCompilationTests {
372377
XCTAssertTrue(mandatoryJobInputs.contains("main.swift"))
373378
}
374379

375-
// Source file timestamps updated but contents are the same, and file-hashing is explicitly disabled
380+
// Source file timestamps updated but contents are the same, and file-hashing is explicitly disabled
376381
func testExplicitIncrementalBuildSourceFilesWithoutHashing() throws {
377382
try buildInitialState(extraArguments: ["-disable-incremental-file-hashing"], explicitModuleBuild: true)
378383
touch("main")
@@ -1043,7 +1048,7 @@ extension IncrementalCompilationTests {
10431048
}
10441049

10451050
private func testRemoval(_ options: RemovalTestOptions) throws {
1046-
setUp() // clear derived data, restore output file map
1051+
try setUpWithError() // clear derived data, restore output file map
10471052
print("\n*** testRemoval \(options) ***", to: &stderrStream); stderrStream.flush()
10481053

10491054
let newInput = "another"

0 commit comments

Comments
 (0)