@houwert/conductor 0.32.0 → 0.32.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -35,6 +35,22 @@ const output_js_1 = require("../output.js");
|
|
|
35
35
|
const utils_js_1 = require("../utils.js");
|
|
36
36
|
const cli_js_1 = require("../drivers/vega/cli.js");
|
|
37
37
|
const discovery_js_1 = require("../drivers/roku/discovery.js");
|
|
38
|
+
/**
|
|
39
|
+
* Show the simulator window. Xcode 27 replaced Simulator.app with DeviceHub.app,
|
|
40
|
+
* so fall back to the hub when Simulator.app is absent.
|
|
41
|
+
*/
|
|
42
|
+
function openSimulatorUI() {
|
|
43
|
+
const tryOpen = (args, next) => {
|
|
44
|
+
const p = (0, child_process_1.spawn)('open', args, { detached: true, stdio: 'ignore' });
|
|
45
|
+
p.on('error', () => next?.());
|
|
46
|
+
p.on('exit', (code) => {
|
|
47
|
+
if (code !== 0)
|
|
48
|
+
next?.();
|
|
49
|
+
});
|
|
50
|
+
p.unref();
|
|
51
|
+
};
|
|
52
|
+
tryOpen(['-a', 'Simulator'], () => tryOpen(['-b', 'com.apple.dt.Devices']));
|
|
53
|
+
}
|
|
38
54
|
const IOS_BOOT_TIMEOUT_MS = 120000;
|
|
39
55
|
const ANDROID_BOOT_TIMEOUT_MS = 120000;
|
|
40
56
|
const POLL_MS = 1000;
|
|
@@ -252,8 +268,7 @@ async function startIOS(osVersion, opts, name, deviceType) {
|
|
|
252
268
|
return 1;
|
|
253
269
|
}
|
|
254
270
|
}
|
|
255
|
-
|
|
256
|
-
(0, child_process_1.spawn)('open', ['-a', 'Simulator'], { detached: true, stdio: 'ignore' }).unref();
|
|
271
|
+
openSimulatorUI();
|
|
257
272
|
const displayName = name ?? device.name;
|
|
258
273
|
// Prewarm the driver so the first interaction command is not the
|
|
259
274
|
// one that pays the XCTest runner startup cost.
|
|
@@ -416,8 +431,7 @@ async function startTvOS(osVersion, opts, name, deviceType) {
|
|
|
416
431
|
return 1;
|
|
417
432
|
}
|
|
418
433
|
}
|
|
419
|
-
|
|
420
|
-
(0, child_process_1.spawn)('open', ['-a', 'Simulator'], { detached: true, stdio: 'ignore' }).unref();
|
|
434
|
+
openSimulatorUI();
|
|
421
435
|
const displayName = name ?? device.name;
|
|
422
436
|
// Prewarm the driver so the first interaction command is not the
|
|
423
437
|
// one that pays the XCTest runner startup cost.
|