Skip to content

Commit cfbe360

Browse files
Handle both SwiftArgParser 0.3.x and 0.4.x output. (#3338) (#3418)
rdar://75172724 (cherry picked from commit a408582) Co-authored-by: Anders Bertelrud <[email protected]>
1 parent 609d57e commit cfbe360

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Tests/CommandsTests/RunToolTests.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ final class RunToolTests: XCTestCase {
2323
}
2424

2525
func testUsage() throws {
26-
XCTAssert(try execute(["--help"]).stdout.contains("USAGE: swift run <options>"))
26+
let stdout = try execute(["-help"]).stdout
27+
XCTAssert(stdout.contains("USAGE: swift run <options>") || stdout.contains("USAGE: swift run [<options>]"), "got stdout:\n" + stdout)
2728
}
2829

2930
func testSeeAlso() throws {

0 commit comments

Comments
 (0)