@openfin/automation-helpers
Version:
Helper methods for automation testing in the OpenFin ecosystem
23 lines (22 loc) • 1.02 kB
TypeScript
import type { ThenableWebDriver } from "selenium-webdriver";
import type { IWebDriverWindow } from "../models/IWebDriverWindow";
import { BaseWebDriverWindow } from "./baseWebDriverWindow";
/**
* Webdriver window for the Selenium environment.
*/
export declare class SeleniumWebDriverWindow extends BaseWebDriverWindow<ThenableWebDriver> implements IWebDriverWindow {
/**
* Switch to the window handle and catch exceptions.
* @param client The client to use for switching.
* @param handle The window to switch to.
* @param activateNativeWindow Activate the native window as well.
* @returns True if switched to the window.
*/
static safeSwitchToWindow(client: ThenableWebDriver, handle: string, activateNativeWindow?: boolean): Promise<boolean>;
/**
* Switch to the window.
* @param activateNativeWindow Activate the native window as well.
* @returns True if the switch was successful.
*/
switchTo(activateNativeWindow?: boolean): Promise<boolean>;
}