mirror of
https://github.com/microsoft/playwright.git
synced 2025-06-26 21:40:17 +00:00
chore: fix firefox tests after switching to context delegate (#34898)
This commit is contained in:
parent
e091baad79
commit
954457ba9e
@ -555,7 +555,7 @@ export class FFPage implements PageDelegate {
|
|||||||
const context = await parent._mainContext();
|
const context = await parent._mainContext();
|
||||||
const result = await this._session.send('Page.adoptNode', {
|
const result = await this._session.send('Page.adoptNode', {
|
||||||
frameId: frame._id,
|
frameId: frame._id,
|
||||||
executionContextId: ((context as any)[contextDelegateSymbol] as FFExecutionContext)._executionContextId
|
executionContextId: (context.delegate as FFExecutionContext)._executionContextId
|
||||||
});
|
});
|
||||||
if (!result.remoteObject)
|
if (!result.remoteObject)
|
||||||
throw new Error('Frame has been detached.');
|
throw new Error('Frame has been detached.');
|
||||||
@ -570,5 +570,3 @@ export class FFPage implements PageDelegate {
|
|||||||
function webSocketId(frameId: string, wsid: string): string {
|
function webSocketId(frameId: string, wsid: string): string {
|
||||||
return `${frameId}---${wsid}`;
|
return `${frameId}---${wsid}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
const contextDelegateSymbol = Symbol('delegate');
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user