geckodriver in selenium webdriver 3.0 beta

0 votes

I was using geckodriver for selenium webdriver 3.0 beta release.Below is the code

WebDriver driver = new FirefoxDriver();
System.setProperty("webdriver.gecko.driver", "//lib//geckodriver");
driver.get("/");

but I got an error:

Exception in thread "main" java.lang.IllegalStateException:

The path to the driver executable must be set by the webdriver.gecko.driver system property; for more information, seehttps://github.com/mozilla/geckodriver.

Apr 9, 2018 in Selenium by ajs3033
• 7,240 points
111 views

1 answer to this question.

0 votes

Check this out

System.setProperty("webdriver.gecko.driver", "pathTogeckodriver");
DesiredCapabilities capabilities = DesiredCapabilities.firefox();
capabilities.setCapability("marionette", true);
WebDriver driver = new FirefoxDriver(capabilities);
answered Apr 9, 2018 by Christine
• 15,790 points

Related Questions In Selenium

0 votes
1 answer

How can I setup Selenium Grid in Selenium 3.0

Below is the stepwise solution for setting ...READ MORE

answered Apr 27, 2018 in Selenium by Meci Matt
• 9,400 points
117 views
0 votes
1 answer

Is Selenium 3.6.0 & webdriver = new FirefoxDriver(capabilities) - deprecated?

Check this out: https://raw.githubusercontent.com/SeleniumHQ/selenium/master/rb/CHANGES 3.4.1 (2017-06-13) ================== Firefox: * Added ...READ MORE

answered May 17, 2018 in Selenium by Samarpit
• 5,130 points
553 views
0 votes
1 answer
0 votes
1 answer

How to run Selenium 1.0 tests in Selenium Webdriver?

Hey @Ipshita, We can use WebDriverBackedSelenium() method to ...READ MORE

answered Jul 2 in Selenium by Anvi
• 10,750 points
14 views
0 votes
3 answers

How to specify "ENTER" button functionality in Selenium WebDriver code?

using OpenQA.Selenium.Interactions; Actions builder = new Actions(driver); ...READ MORE

answered Feb 12 in Selenium by anonymous
6,496 views
0 votes
1 answer

Finding WebDriver element with Class Name in java

The better way to handle this element ...READ MORE

answered Apr 10, 2018 in Selenium by nsv999
• 5,050 points
278 views
0 votes
1 answer
0 votes
1 answer

Geo-location microphone camera pop up

To Allow or Block the notification, access using Selenium and you have to ...READ MORE

answered May 11, 2018 in Selenium by Samarpit
• 5,130 points
640 views
0 votes
1 answer

How to use such xpath to find web elements

It's much simpler to use: #MyDiv123 > div.super or ...READ MORE

answered Jun 14, 2018 in Selenium by Samarpit
• 5,130 points
268 views