mirror of
https://github.com/microsoft/playwright.git
synced 2024-12-14 13:45:36 +03:00
test: ctrl+click during provisional load (#11710)
This commit is contained in:
parent
ac36608a69
commit
312ab57f02
@ -184,3 +184,17 @@ it('should work with Ctrl-clicking', async ({ browser, server, isMac, browserNam
|
||||
expect(await popup.opener()).toBe(null);
|
||||
await context.close();
|
||||
});
|
||||
|
||||
it('should not hang on ctrl-click during provisional load', async ({ context, page, server, isMac, browserName }) => {
|
||||
it.info().annotations.push({ type: 'issue', description: 'https://github.com/microsoft/playwright/issues/11595' });
|
||||
it.skip(browserName === 'chromium', 'Chromium does not dispatch renderer messages while navigation is provisional.');
|
||||
await page.goto(server.EMPTY_PAGE);
|
||||
await page.setContent('<a href="/one-style.html">yo</a>');
|
||||
server.setRoute('/slow.html', () => {});
|
||||
const [popup] = await Promise.all([
|
||||
context.waitForEvent('page'),
|
||||
server.waitForRequest('/slow.html').then(() => page.click('a', { modifiers: [ isMac ? 'Meta' : 'Control'] })),
|
||||
page.evaluate(url => setTimeout(() => location.href = url, 0), server.CROSS_PROCESS_PREFIX + '/slow.html'),
|
||||
]);
|
||||
expect(popup).toBeTruthy();
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user