(selector: DeviceSelector, context: DeviceSelectionContext)
| 320 | } |
| 321 | |
| 322 | function throwNoDevicesFound(selector: DeviceSelector, context: DeviceSelectionContext): never { |
| 323 | const simulatorSetPath = context.simulatorSetPath; |
| 324 | if (simulatorSetPath && supportsAppleSimulatorSelection(selector.platform)) { |
| 325 | throw new AppError('DEVICE_NOT_FOUND', 'No devices found in the scoped simulator set', { |
| 326 | simulatorSetPath, |
| 327 | hint: `The simulator set at "${simulatorSetPath}" appears to be empty. Create a compatible simulator first with xcrun simctl --set "${simulatorSetPath}" create, or remove the scoped simulator set.`, |
| 328 | selector, |
| 329 | }); |
| 330 | } |
| 331 | throw new AppError('DEVICE_NOT_FOUND', 'No devices found', { selector }); |
| 332 | } |
| 333 | |
| 334 | function normalizeDeviceName(value: string): string { |
| 335 | return value.toLowerCase().replace(/_/g, ' ').replace(/\s+/g, ' ').trim(); |
no test coverage detected