You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[tests] Fix CreateAndBuildProjectTemplate hang/flakiness for Mac Catalyst (#26564)
Two issues in the 'Execute'/'DeleteSavedState' helpers used by the Mac Catalyst 'CreateAndBuildProjectTemplate' tests could cause the test process to hang for 30 seconds (or longer) waiting on an unattended 'Do you want to try to reopen its windows again?' AppKit modal dialog:
* 'DeleteSavedState' only deleted '<bundleid>.savedState', but macOS stores Mac Catalyst apps' saved state under '<bundleid>~iosmac.savedState' (the 'iosmac' personality suffix), so the saved state was never actually being cleaned up.
* Even with a clean Saved Application State folder, AppKit also tracks a separate persistent 'crash history' per bundle identifier that isn't stored in that folder and isn't cleared by deleting it. After many crashed/killed test runs sharing the same default bundle identifier, this alone could still trigger the modal.
Fix both: delete the '~iosmac' saved-state variant too, and set the application default 'ApplePersistenceIgnoreState' to 'YES', which tells AppKit to skip the restore-prompt flow entirely regardless of any tracked crash history.
Copilot-Session: 0d41380a-e6ee-470e-b837-68411050a4f6
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
0 commit comments