Skip to content

Commit e8bf432

Browse files
authored
fix(device): keep iOS 17, iPhone 16 Pro and iPhone 16 Pro Max in the … (#290)
fix(device): keep iOS 17, iPhone 16 Pro and iPhone 16 Pro Max in the help text iOS 17, iphone-16-pro and iphone-16-pro-max stay supported until a later removal, so the --ios-device and --ios-version help text lists them again. iphone-15, iphone-16-plus and ipad-pro-6th-gen stay removed, and the default mirror stays iphone-16 / iOS 26. The validation test fixture gives iphone-14 iOS 17 and 18 again, as the API does; a device-only iphone-14 request still fails because iOS 26 is not offered, and its message now lists 17, 18.
1 parent ac75b8f commit e8bf432

2 files changed

Lines changed: 6 additions & 3 deletions

File tree

‎src/types/domain/device.types.ts‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@ export enum EiOSDevices {
1818
'ipad-pro-m5-13' = 'ipad-pro-m5-13',
1919
'iphone-14' = 'iphone-14',
2020
'iphone-16' = 'iphone-16',
21+
'iphone-16-pro' = 'iphone-16-pro',
22+
'iphone-16-pro-max' = 'iphone-16-pro-max',
2123
'iphone-17' = 'iphone-17',
2224
'iphone-18-pro' = 'iphone-18-pro',
2325
'iphone-18-pro-max' = 'iphone-18-pro-max',
@@ -39,6 +41,7 @@ export enum EAndroidDevices {
3941

4042
export enum EiOSVersions {
4143
'eighteen' = '18',
44+
'seventeen' = '17',
4245
'twentySeven' = '27',
4346
'twentySix' = '26',
4447
}

‎test/unit/device-validation.service.test.ts‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import type { CompatibilityData } from '../../src/utils/compatibility.js';
1111
*/
1212
const compat: CompatibilityData = {
1313
ios: {
14-
'iphone-14': ['18'],
14+
'iphone-14': ['17', '18'],
1515
'iphone-16': ['18', '26', '27'],
1616
'iphone-17': ['26', '27'],
1717
'iphone-19': ['28'],
@@ -117,7 +117,7 @@ describe('DeviceValidationService', () => {
117117

118118
it('rejects an unsupported explicit pair with the device\'s versions', () => {
119119
expect(() => ios('27', 'iphone-14')).to.throw(
120-
/^iphone-14 only supports these iOS versions: 18$/,
120+
/^iphone-14 only supports these iOS versions: 17, 18$/,
121121
);
122122
expect(() => android('34', 'pixel-10')).to.throw(
123123
/^pixel-10 only supports these Android API levels: 36, 37$/,
@@ -136,7 +136,7 @@ describe('DeviceValidationService', () => {
136136
describe('requests that rely on a default', () => {
137137
it('tells a device-only iOS request to pass the version explicitly', () => {
138138
expect(() => ios(undefined, 'iphone-14')).to.throw(
139-
'iphone-14 only supports these iOS versions: 18. No iOS version was given, so the default (26) was checked: pass one of those explicitly with --ios-version',
139+
'iphone-14 only supports these iOS versions: 17, 18. No iOS version was given, so the default (26) was checked: pass one of those explicitly with --ios-version',
140140
);
141141
});
142142

0 commit comments

Comments
 (0)