fix: win.closeFilePreview recreates panel when called twice (#45319)

* fix: close quick look during tests on macOS

* use longer delay 🤷

* fix: sharedPreviewPanel being recreated on close

* test: ensure preview panel gets closed
This commit is contained in:
Sam Maddock 2025-02-17 17:25:19 -05:00 committed by GitHub
parent c0422d7cc9
commit 6be1151ffc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 5 additions and 1 deletions

View file

@ -6256,6 +6256,7 @@ describe('BrowserWindow module', () => {
w.previewFile(__filename);
await setTimeout(500);
expect(showCalled).to.equal(false, 'should not have called show twice');
w.closeFilePreview();
});
});