import { remote } from 'webdriverio';
import { Orientation } from '@mablhq/test-model/types/mobile/SetOrientationStepDescriptor';
import { BrowserSize, MobileDeviceInfo } from '../../mobile/types';
import { MobileConsoleLogger } from '@mablhq-internal/runtime/execution';
import { AppiumServerInstance, AppiumSeverEvent, InferredAppiumServerStatusEvent } from './AppiumServerInstance';
import { LiveViewInfo, MobileAppConfig, MobileEnvConfig } from './types';
type WebdriverIOConfig = Parameters<typeof remote>[0];
export declare const DEFAULT_APPIUM_SERVER_HOST = "127.0.0.1";
export declare const DEFAULT_APPIUM_SERVER_PORT = 4723;
export declare const DEFAULT_MJPEG_SERVER_HOST = "127.0.0.1";
export declare const DEFAULT_UI_STREAM_PORT_IOS = 9100;
export declare const DEFAULT_UI_STREAM_PORT_ANDROID = 9101;
export declare class MobileTestEnvironment {
    private config;
    private driver?;
    server?: AppiumServerInstance;
    private testDirectoryPath;
    private liveViewInfo?;
    private currentOrientation?;
    private windowSize?;
    private deviceScaleFactor?;
    private deviceScreenInfo?;
    private originalAppId?;
    private androidDeviceSerialId;
    private cloudTrainingAndroidAppPath;
    private cachedIsIPadDevice;
    private cloudTrainingConnections?;
    log?: MobileConsoleLogger;
    constructor(config: MobileEnvConfig, logger?: MobileConsoleLogger);
    getConfiguredAppiumServerHost(): string;
    getRunningAppiumServerHost(): string;
    getConfiguredAppiumServerPort(): number;
    getRunningAppiumServerPort(): number;
    getRunningUserInterfaceStreamHost(): string;
    getConfiguredUserInterfaceStreamPort(): number;
    getRunningUserInterfaceStreamPort(): number;
    getUserInterfaceStreamUrl(): string;
    isRemoteAppiumServerConfigured(): boolean;
    getWebDriverOptions(): Promise<WebdriverIOConfig>;
    private setiOSWebDriverOptionsOnCapabilities;
    private setAndroidWebDriverOptionsOnCapabilities;
    private openCloudTrainingConnections;
    initialize(): Promise<void>;
    private initializeRemoteAppiumServer;
    private initializeLocalAppiumServer;
    getAppUnderTestId(): Promise<string | undefined>;
    maybeUpdateAppUnderTestId(): Promise<void>;
    setAppUnderTestId(): Promise<void>;
    private getFirstEmulatorName;
    enableScreenRecording(): Promise<void>;
    saveScreenRecording(fileName: string): Promise<void>;
    stopScreenRecording(): Promise<void>;
    saveScreenshot(filePath: string): Promise<Buffer>;
    getDriver(): WebdriverIO.Browser;
    getLiveViewInfo(): LiveViewInfo | undefined;
    getConfig(): MobileEnvConfig;
    getCloudTrainingAndroidAppPath(): string | undefined;
    getOrientation(): Promise<Orientation>;
    setOrientation(orientation: Orientation): Promise<void>;
    getWindowSize(): Promise<BrowserSize>;
    getDeviceScaleFactor(): Promise<number>;
    getDeviceScreenSizeScaled(): Promise<BrowserSize>;
    private getAndroidSessionScreenSize;
    resetEnvironment(): Promise<void>;
    isElementDisplayedInViewport(element: WebdriverIO.Element | undefined): Promise<boolean>;
    shutdown(leaveDeviceOpen?: boolean): Promise<void>;
    createTempDirForTestArtifacts(): string;
    private getLastBootedIPhoneSimulatorUdid;
    private getOrCreateChromeDriverDownloadDirectory;
    getMobileDeviceInfo(): Promise<MobileDeviceInfo>;
    isIPadDevice(): Promise<boolean>;
}
export declare function interpretMobileServerEvent(mobileAppConfig: MobileAppConfig, event: InferredAppiumServerStatusEvent | AppiumSeverEvent): string;
export {};
//# sourceMappingURL=MobileTestEnvironment.d.ts.map