diff --git a/test/testUtil.ts b/test/testUtil.ts index 114c7a51..3d3daf02 100644 --- a/test/testUtil.ts +++ b/test/testUtil.ts @@ -111,7 +111,7 @@ export class TestUtil { // get the most recent iOS simulator to run tests on this.getProcessOutput("xcrun simctl list") .then(function (listOfDevicesWithDevicePairs) { - var listOfDevices: string = listOfDevicesWithDevicePairs.slice(0, listOfDevicesWithDevicePairs.indexOf("== Device Pairs ==")); + var listOfDevices: string = listOfDevicesWithDevicePairs.slice(listOfDevicesWithDevicePairs.indexOf("-- iOS"), listOfDevicesWithDevicePairs.indexOf("-- tvOS")); var phoneDevice = /iPhone (\S* )*(\(([0-9A-Z-]*)\))/g; var match = listOfDevices.match(phoneDevice); onReadIOSEmuName(match[match.length - 1]);