Skip to content

Commit 170b023

Browse files
committed
Fix build issue on Linux
1 parent 2e89e0c commit 170b023

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

Sources/Commands/SwiftTestTool.swift

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -932,9 +932,14 @@ final class ParallelTestRunner {
932932
let thread = Thread {
933933
// Dequeue a specifier and run it till we encounter nil.
934934
while let test = self.pendingTests.dequeue() {
935+
#if os(macOS)
936+
let additionalArguments = ["-XCTest", test.specifier]
937+
#else
938+
let additionalArguments = [test.specifier]
939+
#endif
935940
let testRunner = TestRunner(
936941
bundlePaths: [test.productPath],
937-
additionalArguments: ["-XCTest", test.specifier],
942+
additionalArguments: additionalArguments,
938943
cancellator: self.cancellator,
939944
toolchain: self.toolchain,
940945
testEnv: testEnv,

0 commit comments

Comments
 (0)