UNPKG

appium-ios-simulator

Version:
35 lines 1.87 kB
import type { CoreSimulator, SupportsAppPermissions } from '../types'; import type { StringRecord } from '@appium/types'; type CoreSimulatorWithAppPermissions = CoreSimulator & SupportsAppPermissions; /** * Sets the particular permission to the application bundle. See https://github.com/wix/AppleSimulatorUtils * or `xcrun simctl privacy` for more details on the available service names and statuses. * * @param bundleId Application bundle identifier. * @param permission Service name to be set. * @param value The desired status for the service. * @throws {Error} If there was an error while changing permission. */ export declare function setPermission(this: CoreSimulatorWithAppPermissions, bundleId: string, permission: string, value: string): Promise<void>; /** * Sets the permissions for the particular application bundle. * * @param bundleId Application bundle identifier. * @param permissionsMapping A mapping where keys * are service names and values are their corresponding status values. * See https://github.com/wix/AppleSimulatorUtils or `xcrun simctl privacy` * for more details on available service names and statuses. * @throws {Error} If there was an error while changing permissions. */ export declare function setPermissions(this: CoreSimulatorWithAppPermissions, bundleId: string, permissionsMapping: StringRecord): Promise<void>; /** * Retrieves current permission status for the given application bundle. * * @param bundleId Application bundle identifier. * @param serviceName One of available service names. * @returns Promise that resolves to the permission status * @throws {Error} If there was an error while retrieving permissions. */ export declare function getPermission(this: CoreSimulatorWithAppPermissions, bundleId: string, serviceName: string): Promise<string>; export {}; //# sourceMappingURL=permissions.d.ts.map