fix(webkit): do not fire FrameNavigated when receive resource tree

This commit is contained in:
Yury Semikhatsky 2020-01-08 15:28:17 -08:00
parent 73b148a0c6
commit 8f2f10decc
2 changed files with 2 additions and 2 deletions

View file

@ -119,9 +119,9 @@ export class FrameManager {
if (!initial) { if (!initial) {
for (const watcher of this._lifecycleWatchers) for (const watcher of this._lifecycleWatchers)
watcher._onCommittedNewDocumentNavigation(frame); watcher._onCommittedNewDocumentNavigation(frame);
}
this._page.emit(Events.Page.FrameNavigated, frame); this._page.emit(Events.Page.FrameNavigated, frame);
} }
}
frameCommittedSameDocumentNavigation(frameId: string, url: string) { frameCommittedSameDocumentNavigation(frameId: string, url: string) {
const frame = this._frames.get(frameId); const frame = this._frames.get(frameId);

View file

@ -97,7 +97,7 @@ module.exports.describe = function({testRunner, expect, FFOX, CHROME, WEBKIT}) {
await page.goto(server.EMPTY_PAGE); await page.goto(server.EMPTY_PAGE);
expect(await frameEvaluation).toBe(42); expect(await frameEvaluation).toBe(42);
}); });
it.skip(WEBKIT)('should work right after a cross-origin navigation', async({page, server}) => { it('should work right after a cross-origin navigation', async({page, server}) => {
await page.goto(server.EMPTY_PAGE); await page.goto(server.EMPTY_PAGE);
let frameEvaluation = null; let frameEvaluation = null;
page.on('framenavigated', async frame => { page.on('framenavigated', async frame => {