webdriverio
Version:
Next-gen browser and mobile automation test framework for Node.js
18 lines • 955 B
TypeScript
import type WebDriverInterception from './index.js';
/**
* The mocks `mockClearAll()` and `mockRestoreAll()` act on: on a tab, the mocks made
* for that tab; in a parallel test, the mocks that test created, also on tabs it opened;
* otherwise every mock of the session. `SESSION_MOCKS` also holds the mocks of the other
* instances of a multi-remote browser.
*/
export declare function mocksOf(scope: WebdriverIO.Browser | WebdriverIO.BrowsingContext): WebDriverInterception[];
/**
* Every mock of the session of a browser, whatever tab or parallel test made it.
*/
export declare function sessionMocksOf(browser: WebdriverIO.Browser): WebDriverInterception[];
/**
* Restores the given mocks. A mock that can't be restored does not keep the others
* from it; its error is thrown afterwards, all of them when several fail.
*/
export declare function restoreMocks(mocks: WebDriverInterception[]): Promise<void>;
//# sourceMappingURL=scope.d.ts.map