Skip to main content

Apr 17, 2013 - 2 minute read - Selenium Simplified Blog WebDriver

OperaDriver 1.2 With Selenium 2.32.0 on Windows 8

“Hmm, why aren’t my tests on Opera working any more?”

For those of you that want to skip to the chase and see my hack then I did this, just before I created a new OperaDriver();

driver = new OperaDriver();

And thanks to you for sticking around to see the investigation process…

Caused by: org.openqa.selenium.WebDriverException: 
Could not find a platform that supports bundled launchers, 
please set it manually
Build info: version: '2.32.0', revision: 
'6c40c187d01409a5dc3b7f8251859150c8af0bcb', time: '2013-04-09 10:39:28'
System info: 'Windows 8', os.arch: 'amd64', 
os.version: '6.2', java.version: '1.7.0_10'
Driver info: driver.version: OperaDriver
    ... 34 more

Umm. OK. That’s new for me. I wonder how to set the platform manually?

I jumped off to the line of code in the OperaLauncherRunner, which was an enum. Did a quick evaluate on Platform.getCurrent(); which had correctly identified my current operating system as WIN8.

But sadly the switch statement in launcherNameForOS doesn’t cater for WIN8, so I set the platform manually by changing the “” property, and I set it to “windows” to pretend I’m running on XP.

driver = new OperaDriver();

I also used “win7” and pretended to be VISTA. Same result, so I thought using “windows” was probably the most explanatory in the code.

And voila. My tests were running in Opera again.

You will need a Github account to comment. Or you can contact me with your comment.

I reserve the right to delete spam comments e.g. if your comment adds no value and its purpose is simply to create a backlink to another site offering training, or courses, etc.