Skip to content

Commit

Permalink
chore: improve "Page.close should run beforeunload if asked for" unit…
Browse files Browse the repository at this point in the history
… test for Firefox (#6995)
  • Loading branch information
whimboo committed Mar 16, 2021
1 parent 5f24f60 commit bf60a30
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions test/page.spec.ts
Expand Up @@ -67,10 +67,7 @@ describe('Page', function () {
expect(dialog.type()).toBe('beforeunload');
expect(dialog.defaultValue()).toBe('');
if (isChrome) expect(dialog.message()).toBe('');
else
expect(dialog.message()).toBe(
'This page is asking you to confirm that you want to leave - data you have entered may not be saved.'
);
else expect(dialog.message()).toBeTruthy();
await dialog.accept();
await pageClosingPromise;
});
Expand Down

0 comments on commit bf60a30

Please sign in to comment.