diff --git a/src/devices/IOSDevice.js b/src/devices/IOSDevice.js index 0d013ddec..e4a405a83 100644 --- a/src/devices/IOSDevice.js +++ b/src/devices/IOSDevice.js @@ -63,10 +63,15 @@ export default class IOSDevice extends BaseDevice { return; } if (!this.log) { + const deviceSetPath = process.env.DEVICE_SET_PATH + ? ['--set', process.env.DEVICE_SET_PATH] + : []; + this.log = child_process.spawn( 'xcrun', [ 'simctl', + ...deviceSetPath, 'spawn', 'booted', 'log', diff --git a/src/dispatcher/iOSDevice.js b/src/dispatcher/iOSDevice.js index cee8db1dc..4a068886c 100644 --- a/src/dispatcher/iOSDevice.js +++ b/src/dispatcher/iOSDevice.js @@ -100,9 +100,16 @@ function queryDevices(store: Store, logger: Logger): Promise { } function getActiveSimulators(): Promise> { - return promisify(execFile)('xcrun', ['simctl', 'list', 'devices', '--json'], { - encoding: 'utf8', - }) + const deviceSetPath = process.env.DEVICE_SET_PATH + ? ['--set', process.env.DEVICE_SET_PATH] + : []; + return promisify(execFile)( + 'xcrun', + ['simctl', ...deviceSetPath, 'list', 'devices', '--json'], + { + encoding: 'utf8', + }, + ) .then(({stdout}) => JSON.parse(stdout).devices) .then(simulatorDevices => { const simulators: Array = Object.values(