appium-adb
Version:
Android Debug Bridge interface
61 lines • 2.64 kB
TypeScript
import type { ADB } from '../adb';
import type { InstallMultipleApksOptions, InstallApksOptions } from './types';
/**
* Executes bundletool utility with given arguments and returns the actual stdout
*
* @param args - the list of bundletool arguments
* @param errorMsg - The customized error message string
* @returns the actual command stdout
* @throws {Error} If bundletool jar does not exist in PATH or there was an error while
* executing it
*/
export declare function execBundletool(this: ADB, args: string[], errorMsg: string): Promise<string>;
/**
*
* @param specLocation - The full path to the generated device spec location
* @returns The same `specLocation` value
* @throws {Error} If it is not possible to retrieve the spec for the current device
*/
export declare function getDeviceSpec(this: ADB, specLocation: string): Promise<string>;
/**
* Installs the given apks into the device under test
*
* @param apkPathsToInstall - The full paths to install apks
* @param options - Installation options
*/
export declare function installMultipleApks(this: ADB, apkPathsToInstall: string[], options?: InstallMultipleApksOptions): Promise<string>;
/**
* Installs the given .apks package into the device under test
*
* @param apks - The full path to the .apks file
* @param options - Installation options
* @throws {Error} If the .apks bundle cannot be installed
*/
export declare function installApks(this: ADB, apks: string, options?: InstallApksOptions): Promise<void>;
/**
* Extracts and returns the full path to the master .apk file inside the bundle.
*
* @param apks - The full path to the .apks file
* @returns The full path to the master bundle .apk
* @throws {Error} If there was an error while extracting/finding the file
*/
export declare function extractBaseApk(this: ADB, apks: string): Promise<string>;
/**
* Extracts and returns the full path to the .apk, which contains the corresponding
* resources for the given language in the .apks bundle.
*
* @param apks - The full path to the .apks file
* @param language - The language abbreviation. The default language is
* going to be selected if it is not set.
* @returns The full path to the corresponding language .apk or the master .apk
* if language split is not enabled for the bundle.
* @throws {Error} If there was an error while extracting/finding the file
*/
export declare function extractLanguageApk(this: ADB, apks: string, language?: string | null): Promise<string>;
/**
*
* @param output
* @returns
*/
export declare function isTestPackageOnlyError(output: string): boolean;
//# sourceMappingURL=apks-utils.d.ts.map