Skip to content

Commit

Permalink
fix: system prompt for Apple ID sign in unexpectedly not translated (#…
Browse files Browse the repository at this point in the history
…431)

* fix: system prompt for Apple ID sign in unexpectedly not translated

* fix: unit test
  • Loading branch information
mwakizaka committed Jun 5, 2024
1 parent 6cfa521 commit 9c3bb77
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
3 changes: 2 additions & 1 deletion lib/extensions/settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ import { fs } from '@appium/support';
// com.apple.SpringBoard: translates com.apple.SpringBoard and system prompts for push notification
// com.apple.locationd: translates system prompts for location
// com.apple.tccd: translates system prompts for camera, microphone, contact, photos and app tracking transparency
const SERVICES_FOR_TRANSLATION = ['com.apple.SpringBoard', 'com.apple.locationd', 'com.apple.tccd'];
// com.apple.akd: translates `Sign in with your Apple ID` system prompt
const SERVICES_FOR_TRANSLATION = ['com.apple.SpringBoard', 'com.apple.locationd', 'com.apple.tccd', 'com.apple.akd'];
const GLOBAL_PREFS_PLIST = '.GlobalPreferences.plist';
const PREFERENCES_PLIST_GUARD = new AsyncLock();
const DOMAIN = /** @type {const} */ Object.freeze({
Expand Down
5 changes: 4 additions & 1 deletion test/unit/simulator-specs.js
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,10 @@ launchd_s 35621 mwakizaka 16u unix 0x7b7dbedd6d62e84f 0t0 /private/
spawnProcessSpy.getCall(3).args[0].should.eql(
['launchctl', 'stop', 'com.apple.tccd']
);
spawnProcessSpy.callCount.should.eql(4);
spawnProcessSpy.getCall(4).args[0].should.eql(
['launchctl', 'stop', 'com.apple.akd']
);
spawnProcessSpy.callCount.should.eql(5);
});

it('should confirm skip restarting services if already applied', async function () {
Expand Down

0 comments on commit 9c3bb77

Please sign in to comment.