(command, args, options = {})
| 742 | } |
| 743 | |
| 744 | function runText(command, args, options = {}) { |
| 745 | const result = spawnSync(command, args, { |
| 746 | cwd: root, |
| 747 | encoding: "utf8", |
| 748 | input: options.input, |
| 749 | maxBuffer: options.maxBuffer ?? 32 * 1024 * 1024, |
| 750 | timeout: options.timeoutMs ?? 120_000, |
| 751 | }); |
| 752 | if (result.status !== 0) { |
| 753 | throw new Error( |
| 754 | `${command} ${args.join(" ")} failed with ${result.status ?? result.signal}\n${result.stderr ?? ""}\n${result.error?.message ?? ""}`, |
| 755 | ); |
| 756 | } |
| 757 | return result.stdout; |
| 758 | } |
| 759 | |
| 760 | function openSimulatorApp(udid) { |
| 761 | spawnSync("open", ["-a", "Simulator", "--args", "-CurrentDeviceUDID", udid], { |
no outgoing calls
no test coverage detected