3

I am running into a huge problem regarding selenium 3 automated ui tests. First of all, I clarify how I run selenium tests on Firefox 46 with selenium 2.x:

- Start selenium server on console: java -jar selenium.jar -firefoxProfileTemplate c:\selenium\firefox_profile
- Run (behat) tests from another console 

Now, I've read that Firefox 48 does not support the webdriver anymore, and moved to Marionette webdriver. Ok, so I downloaded Selenium 3 beta with the corresponding geckodriver and startet the above worflow again - it worked BUT:

My site uses a self signed ssl certificate. Ok this was no problem in previous selenium version with webdriver, I could just create a custom firefox profile and use it by appending firefoxProfileTemplate flag. The problem on Selenium 3 with Marionette driver is, that this flag does not exist anymore.

So how to specify the firefox profile, which selenium / Marionette should use when opening firefox, from the command line? Is there a new option? Or maybe a global config file somewhere?

Regards-

Louis
  • 146,715
  • 28
  • 274
  • 320
user3746259
  • 1,491
  • 2
  • 23
  • 46

1 Answers1

1

Not sure which language you're using ,but for java side you can use the old FirefoxProfile to set the firefox driver support SSL. see below code:

    DesiredCapabilities capabilities = DesiredCapabilities.firefox();
    FirefoxProfile fp = new FirefoxProfile();
    // fp.addExtension(extensionToInstall);
    // http://stackoverflow.com/questions/15292972/auto-download-pdf-files-in-firefox
    // http://www.webmaster-toolkit.com/mime-types.shtml
    // for config list see this :
    // http://kb.mozillazine.org/About:config_entries#Profile.
    fp.setAcceptUntrustedCertificates(true);
    fp.setAssumeUntrustedCertificateIssuer(true);
    fp.setEnableNativeEvents(false);
    capabilities.setCapability(FirefoxDriver.PROFILE, fp);

It's a bit hard when selenium switch all the old drivers to W3C WebDriver, there are no much document here for user,hope this helps you.

Alter Hu
  • 739
  • 1
  • 7
  • 15