diff --git a/spec/api-browser-window-spec.ts b/spec/api-browser-window-spec.ts index a1657f76c619..94f627ee2389 100755 --- a/spec/api-browser-window-spec.ts +++ b/spec/api-browser-window-spec.ts @@ -1272,6 +1272,7 @@ describe('BrowserWindow module', () => { // We first need to resign app focus for this test to work const isInactive = once(app, 'did-resign-active'); childProcess.execSync('osascript -e \'tell application "Finder" to activate\''); + defer(() => childProcess.execSync('osascript -e \'tell application "Finder" to quit\'')); await isInactive; // Create new window