Skip to content

Commit 56d88d7

Browse files
committedMar 1, 2015
Restore ability to select Opera in webdriverjs capabilities (accidentally
removed in revision af8b8ee). WebDriverJS only supports Chromium-based Opera (26+), not Presto
1 parent 17872d6 commit 56d88d7

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed
 

Diff for: ‎javascript/webdriver/capabilities.js

+9
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ webdriver.Browser = {
3838
INTERNET_EXPLORER: 'internet explorer',
3939
IPAD: 'iPad',
4040
IPHONE: 'iPhone',
41+
OPERA: 'opera',
4142
PHANTOM_JS: 'phantomjs',
4243
SAFARI: 'safari',
4344
HTMLUNIT: 'htmlunit'
@@ -236,6 +237,14 @@ webdriver.Capabilities.iphone = function() {
236237
};
237238

238239

240+
/**
241+
* @return {!webdriver.Capabilities} A basic set of capabilities for Opera.
242+
*/
243+
webdriver.Capabilities.opera = function() {
244+
return new webdriver.Capabilities().
245+
set(webdriver.Capability.BROWSER_NAME, webdriver.Browser.OPERA);
246+
};
247+
239248
/**
240249
* @return {!webdriver.Capabilities} A basic set of capabilities for
241250
* PhantomJS.

0 commit comments

Comments
 (0)
Please sign in to comment.