Rob--W / selenium

A mirror of the Selenium source. Please log Issues in Google Code. Also confirm you have signed the CLA http://goo.gl/qC50R when making a Pull Request
https://code.google.com/p/selenium/
Apache License 2.0
0 stars 0 forks source link

I dont succeed to use SafariOption #1

Closed badavid closed 11 years ago

badavid commented 11 years ago

I'm on Windows7. Safari 5.1.7 I have copy SafariOption.java on my project workspace and execute this code SafariOptions options = new SafariOptions(); options.addExtensions(new File("pathToMyExtension.safariextz")); DesiredCapabilities capabilities = DesiredCapabilities.safari(); capabilities.setCapability(SafariOptions.CAPABILITY, options); SafariDriver driver = new SafariDriver(capabilities);

The driver open as a SafariDriver correctly. I expected that the extension pathToMyExtension.safariextz who be load on my driver and it's not

Rob--W commented 11 years ago

Copying SafariOptions is not sufficient. Other files are also changed: https://github.com/SeleniumHQ/selenium/pull/87/files. Besides the updated files, you also need all dependencies within your classpath to compile it.

I have put instructions on building the driver with Safari extensions support at the bottom of my post at http://stackoverflow.com/a/17117849/938089, use Ctrl + F "Getting SafariDriver and OperaDriver" to quickly get to the point.

badavid commented 11 years ago

I send you an email

Rob--W commented 11 years ago

I've mailed a build of Selenium with the updated SafariDriver. PR https://github.com/SeleniumHQ/selenium/pull/87 is about to be accepted, so future users can use the new features without much hassle.