File tree Expand file tree Collapse file tree 1 file changed +5
-9
lines changed
Sources/CartonCLI/Commands/TestRunners Expand file tree Collapse file tree 1 file changed +5
-9
lines changed Original file line number Diff line number Diff line change @@ -84,16 +84,12 @@ struct BrowserTestRunner: TestRunner {
84
84
85
85
func launchDriver( executablePath: String ) async throws -> ( URL , Disposer ) {
86
86
let address = try await findAvailablePort ( )
87
- let process = try Foundation . Process. run (
88
- URL ( fileURLWithPath: executablePath) ,
89
- arguments: [ " --port= \( address. port!) " ]
90
- )
87
+ let process = Process ( arguments: [
88
+ executablePath, " --port= \( address. port!) " ,
89
+ ] )
91
90
terminal. logLookup ( " Launch WebDriver executable: " , executablePath)
92
- let disposer = {
93
- // Seems like chromedriver doesn't respond to SIGTERM and SIGINT
94
- kill ( process. processIdentifier, SIGKILL)
95
- process. waitUntilExit ( )
96
- }
91
+ try process. launch ( )
92
+ let disposer = { process. signal ( SIGKILL) }
97
93
return ( URL ( string: " http:// \( address. ipAddress!) : \( address. port!) " ) !, disposer)
98
94
}
99
95
You can’t perform that action at this time.
0 commit comments