mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
test(firefox): further unify Puppeteer-Firefox and Puppeteer tests (#3894)
This patch: - changes Puppeteer-Firefox plumbing of defaultBrowserOptions to align with the way we do it for Puppeteer. - plumbs puppeeteer-dependent Errors and DeviceDescriptors down to every test. - unifies a few tests between Puppeteer-Firefox and Puppeteer. **Note:** in future, we should expose errors as `puppeteer.errors` and device descriptors as `puppeteer.devices` to make it easy to pass around Puppeteer/Puppeteer-Firefox instance. References #3889.
This commit is contained in:
@@ -123,11 +123,9 @@ module.exports.addTests = function({testRunner, expect, product}) {
|
||||
await watchdog;
|
||||
});
|
||||
it('should survive navigations', async({page, server}) => {
|
||||
const watchdog = page.waitForFunction(() => {
|
||||
return window.__done;
|
||||
});
|
||||
const watchdog = page.waitForFunction(() => window.__done);
|
||||
await page.goto(server.EMPTY_PAGE);
|
||||
await page.goto(server.EMPTY_PAGE2);
|
||||
await page.goto(server.PREFIX + '/consolelog.html');
|
||||
await page.evaluate(() => window.__done = true);
|
||||
await watchdog;
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user