fix(webkit): unflake frame detach tests (#509)

This commit is contained in:
Yury Semikhatsky 2020-01-16 11:10:46 -08:00 committed by Dmitry Gozman
parent 9b46014493
commit a2c7553518

View File

@ -67,7 +67,10 @@ export class WKPageProxy {
handleProvisionalLoadFailed(event: Protocol.Browser.provisionalLoadFailedPayload) {
if (!this._wkPage)
return;
this._wkPage._page._frameManager.provisionalLoadFailed(event.loaderId, event.error);
let errorText = event.error;
if (errorText.includes('cancelled'))
errorText += '; maybe frame was detached?';
this._wkPage._page._frameManager.provisionalLoadFailed(event.loaderId, errorText);
}
async page(): Promise<Page> {