()
| 398 | } |
| 399 | |
| 400 | function cleanup() { |
| 401 | if (serverProcess && serverProcess.exitCode === null) { |
| 402 | serverProcess.kill(); |
| 403 | } |
| 404 | if (simulatorUDID) { |
| 405 | spawnSync("xcrun", ["simctl", "shutdown", simulatorUDID], { |
| 406 | stdio: "ignore", |
| 407 | }); |
| 408 | spawnSync("xcrun", ["simctl", "delete", simulatorUDID], { |
| 409 | stdio: "ignore", |
| 410 | }); |
| 411 | } |
| 412 | fs.rmSync(tempRoot, { recursive: true, force: true }); |
| 413 | } |