powerAC
Set the state of the battery charger on the Android emulator. Valid values: 'on', 'off'.
Note: Falls back to the deprecated Appium 2 protocol endpoint if the driver does not support the
mobile:execute method.
Usage
browser.powerAC(state)
Parameters
| Name | Type | Details |
|---|---|---|
state | string | The charger state to set ('on' or 'off') |
Example
powerAC.js
it('should enable the AC charger', async () => {
await browser.powerAC('on')
})
Support
примітка
Refer to the official Appium driver documentation to see which driver versions support this command.