appium-xcuitest-driver
Version:
Appium driver for iOS using XCUITest for backend
65 lines • 2.42 kB
TypeScript
import { type Simulator } from 'appium-ios-simulator';
import type { XCUITestDriver } from '../driver';
export interface SimulatorLookupOptions {
/** The name of the device to lookup */
deviceName?: string;
/** The platform version string */
platformVersion: string;
/** The full path to the simulator devices set */
simulatorDevicesSetPath?: string;
/** Simulator udid */
udid?: string;
/** The name of the current platform */
platformName?: string;
}
export interface SimulatorInstallOptions {
/** Whether to skip app uninstall before installing it */
skipUninstall?: boolean;
/** Whether the simulator is brand new */
newSimulator?: boolean;
}
/**
* Create a new simulator with `appiumTest-` prefix and return the object.
*
* @returns Simulator object associated with the udid passed in.
*/
export declare function createSim(this: XCUITestDriver): Promise<Simulator>;
/**
* Get an existing simulator matching the provided capabilities.
*
* @returns The matched Simulator instance or `null` if no matching device is found.
*/
export declare function getExistingSim(this: XCUITestDriver): Promise<Simulator | null>;
/**
* Shutdown simulator
*/
export declare function shutdownSimulator(this: XCUITestDriver): Promise<void>;
/**
* Run simulator reset
* @param enforceSimulatorShutdown Whether to enforce simulator shutdown
*/
export declare function runSimulatorReset(this: XCUITestDriver, enforceSimulatorShutdown?: boolean): Promise<void>;
/**
* Install app to simulator
* @param app The app to the path
* @param bundleId The bundle id to ensure it is already installed and uninstall it
* @param opts Install options
*/
export declare function installToSimulator(this: XCUITestDriver, app: string, bundleId?: string, opts?: SimulatorInstallOptions): Promise<void>;
/**
* Shutdown other simulators
*/
export declare function shutdownOtherSimulators(this: XCUITestDriver): Promise<void>;
/**
* Configures Safari options based on the given session capabilities
*
* @returns true if any preferences have been updated
*/
export declare function setSafariPrefs(this: XCUITestDriver): Promise<boolean>;
/**
* Changes Simulator localization preferences
*
* @returns True if preferences were changed
*/
export declare function setLocalizationPrefs(this: XCUITestDriver): Promise<boolean>;
//# sourceMappingURL=simulator-management.d.ts.map