webdriverio
Version:
Next-gen browser and mobile automation test framework for Node.js
28 lines • 1.33 kB
TypeScript
export interface BrowsingContextInit {
isFrame: boolean;
url: string;
parent?: WebdriverIO.BrowsingContext;
request?: WebdriverIO.Request;
}
/**
* `browser.addCommand(name, fn, { attachToBrowsingContext: true })`
*/
export declare function addBrowsingContextCommand(browser: WebdriverIO.Browser, name: string, fn: unknown): void;
/**
* `browser.overwriteCommand(name, fn, { attachToBrowsingContext: true })`
*/
export declare function overwriteBrowsingContextCommand(browser: WebdriverIO.Browser, name: string, fn: unknown): void;
/**
* Route `attachToBrowsingContext` registrations of a browser to its browsing
* contexts. Every other registration goes to the browser's own `addCommand`
* and `overwriteCommand`.
*/
export declare function enableBrowsingContextCommands(browser: WebdriverIO.Browser): void;
/**
* A browsing context for one tab, window, or frame. It carries the commands
* that can target a navigable and the custom commands registered with
* `browser.addCommand(name, fn, { attachToBrowsingContext: true })`. It does
* not carry session commands, and `addCommand` stays on the browser.
*/
export declare function getBrowsingContext(browser: WebdriverIO.Browser, contextId: string, init: BrowsingContextInit): WebdriverIO.BrowsingContext;
//# sourceMappingURL=browsingContext.d.ts.map