View Source Improve this doc

setOrientation

Set a device orientation.

Usage

1
browser.setOrientation(orientation);

Parameters

Param Type Details
orientation String the new browser orientation (landscape/portrait)

Example

setOrientation.js
1
2
3
4
5
6
it('should set a geo location for the device', function () {
browser.setOrientation('landscape');

var orientation = browser.getOrientation();
console.log(orientation); // outputs: "landscape"
});

Support

Support for android Support for ios

Uses