Skip to content
This repository has been archived by the owner on Sep 21, 2021. It is now read-only.

Commit

Permalink
[BUA-925] Adding documentation on how to use the new screenResolution…
Browse files Browse the repository at this point in the history
… capability.
  • Loading branch information
diemol committed Mar 21, 2017
1 parent 2575b63 commit 9eabde4
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions docs/usage_examples.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
* [Test name](#test-name)
* [Group name](#group-name)
* [Idle Timeout](#idle-timeout)
* [Screen resolution](#screen-resolution)


## Initial setup
Expand Down Expand Up @@ -246,4 +247,16 @@ capability in your test. Example code in Java for the capability (it sets the `i
desiredCapabilities.setCapability("idleTimeout", 150);
```

### Screen resolution
You can pass a custom screen resolution for your test, just include a `screenResolution` with the desired value. E.g.
`screenResolution=1280x1024`. Also supported for the same purpose `resolution` and `screen-resolution`. Example code
in Java for the capability `screenResolution`

```java
DesiredCapabilities desiredCapabilities = new DesiredCapabilities();
desiredCapabilities.setCapability(CapabilityType.BROWSER_NAME, BrowserType.FIREFOX);
desiredCapabilities.setCapability(CapabilityType.PLATFORM, Platform.LINUX);
desiredCapabilities.setCapability("screenResolution", "1280x720");
```


0 comments on commit 9eabde4

Please sign in to comment.