Skip to content

Commit

Permalink
test: remove workaround for fixed Menu.closePopup issue (#37802)
Browse files Browse the repository at this point in the history
  • Loading branch information
dsanders11 committed Apr 4, 2023
1 parent 0b4ef2b commit 4c8583c
Showing 1 changed file with 3 additions and 12 deletions.
15 changes: 3 additions & 12 deletions spec/api-menu-spec.ts
Expand Up @@ -817,10 +817,7 @@ describe('Menu module', function () {
it('should emit menu-will-close event', (done) => {
menu.on('menu-will-close', () => { done(); });
menu.popup({ window: w });
// https://github.com/electron/electron/issues/19411
setTimeout().then(() => {
menu.closePopup();
});
menu.closePopup();
});

it('returns immediately', () => {
Expand Down Expand Up @@ -849,18 +846,12 @@ describe('Menu module', function () {

expect(x).to.equal(100);
expect(y).to.equal(101);
// https://github.com/electron/electron/issues/19411
setTimeout().then(() => {
menu.closePopup();
});
menu.closePopup();
});

it('works with a given BrowserWindow, no options, and a callback', (done) => {
menu.popup({ window: w, callback: () => done() });
// https://github.com/electron/electron/issues/19411
setTimeout().then(() => {
menu.closePopup();
});
menu.closePopup();
});

it('prevents menu from getting garbage-collected when popuping', async () => {
Expand Down

0 comments on commit 4c8583c

Please sign in to comment.