Skip to content

Commit

Permalink
There is no need to create a profile for Marionette
Browse files Browse the repository at this point in the history
  • Loading branch information
barancev committed Oct 13, 2015
1 parent 9ac0e47 commit c4023d3
Showing 1 changed file with 12 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -59,18 +59,20 @@ public WebDriver get() {
return null;
}

if (DesiredCapabilities.firefox().getBrowserName().
equals(desiredCapsToUse.getBrowserName())) {
if (isInDevMode()) {
copyFirefoxDriverDefaultsToOutputDir();
if (DesiredCapabilities.firefox().getBrowserName().equals(desiredCapsToUse.getBrowserName())) {
boolean isMarionette = Boolean.getBoolean("webdriver.firefox.marionette");
if (!isMarionette) {
if (isInDevMode()) {
copyFirefoxDriverDefaultsToOutputDir();
}

FirefoxProfile profile = new FirefoxProfile();
boolean enableNativeEvents = Boolean.getBoolean("selenium.browser.native_events") ||
Platform.getCurrent().is(WINDOWS);
profile.setEnableNativeEvents(enableNativeEvents);
desiredCapsToUse.setCapability(FirefoxDriver.PROFILE, profile);
}

FirefoxProfile profile = new FirefoxProfile();
boolean enableNativeEvents = Boolean.getBoolean("selenium.browser.native_events") ||
Platform.getCurrent().is(WINDOWS);
profile.setEnableNativeEvents(enableNativeEvents);
desiredCapsToUse.setCapability(FirefoxDriver.PROFILE, profile);

try {
return driverClass.getConstructor(Capabilities.class,
Capabilities.class)
Expand Down

0 comments on commit c4023d3

Please sign in to comment.