forked from enviPath/enviPy
Current Dev State
This commit is contained in:
29
static/js/ketcher2/node_modules/webdriverio/lib/protocol/lock.js
generated
vendored
Normal file
29
static/js/ketcher2/node_modules/webdriverio/lib/protocol/lock.js
generated
vendored
Normal file
@ -0,0 +1,29 @@
|
||||
/**
|
||||
*
|
||||
* Lock the device.
|
||||
*
|
||||
* <example>
|
||||
:lockIt.js
|
||||
it('demonstrate the lock and unlock command', function () {
|
||||
browser.lock();
|
||||
console.log(browser.isLocked()); // true
|
||||
|
||||
browser.unlock();
|
||||
console.log(browser.isLocked()); // false
|
||||
});
|
||||
* </example>
|
||||
*
|
||||
* @param {Number} seconds wait in seconds until lock screen
|
||||
*
|
||||
* @see https://github.com/appium/appium/blob/master/docs/en/writing-running-appium/appium-bindings.md#lock
|
||||
* @type mobile
|
||||
* @for android
|
||||
*
|
||||
*/
|
||||
|
||||
export default function lock (seconds = 0) {
|
||||
return this.requestHandler.create({
|
||||
path: '/session/:sessionId/appium/device/lock',
|
||||
method: 'POST'
|
||||
}, { seconds })
|
||||
}
|
||||
Reference in New Issue
Block a user