Last active
October 11, 2016 23:31
-
-
Save eliasnogueira/069644a12e1021125446000115d47862 to your computer and use it in GitHub Desktop.
Code snippet to update Selenium WebDriver tests with Marionette
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Test | |
public void testeMarionetteDriver() { | |
// you can add the path to gecko driver to your path as well | |
System.setProperty("webdriver.gecko.driver", "C:/drivers/marionette/geckodriver.exe"); | |
WebDriver driver = new MarionetteDriver(); | |
driver.get("http://eliasnogueira.com"); | |
driver.quit(); | |
} | |
@Test | |
public void testFirefoxDriverWithMationnete() { | |
// you can add the path to gecko driver to your path as well | |
System.setProperty("webdriver.gecko.driver", "C:/drivers/marionette/geckodriver.exe"); | |
DesiredCapabilities dc = DesiredCapabilities.firefox(); | |
dc.setCapability("marionette", true); | |
WebDriver driver = new FirefoxDriver(dc); | |
driver.get("http://eliasnogueira.com"); | |
driver.quit(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment