mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
test: await browser closing in tests (#2022)
This commit is contained in:
parent
ae22ef30b3
commit
ee5ec3e630
@ -160,7 +160,7 @@ describe('Puppeteer', function() {
|
||||
const page = await browser.newPage();
|
||||
let error = null;
|
||||
const neverResolves = page.evaluate(() => new Promise(r => {})).catch(e => error = e);
|
||||
browser.close();
|
||||
await browser.close();
|
||||
await neverResolves;
|
||||
expect(error.message).toContain('Protocol error');
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user