Error appears when runing spec with windows 10 through comand line
francorebu opened this issue · 1 comments
Oct 23, 2018 12:00:11 PM org.openqa.selenium.remote.DesiredCapabilities firefox
INFO: Using new FirefoxOptions()
is preferred to DesiredCapabilities.firefox()
java.lang.IllegalStateException: The path to the driver executable must be set by the webdriver.gecko.driver system property; for more information, see https://github.com/mozilla/geckodriver. The latest version can be downloaded from https://github.com/mozilla/geckodriver/releases
at com.google.common.base.Preconditions.checkState(Preconditions.java:847)
at org.openqa.selenium.remote.service.DriverService.findExecutable(DriverService.java:124)
at org.openqa.selenium.firefox.GeckoDriverService.access$100(GeckoDriverService.java:41)
at org.openqa.selenium.firefox.GeckoDriverService$Builder.findDefaultExecutable(GeckoDriverService.java:141)
at org.openqa.selenium.remote.service.DriverService$Builder.build(DriverService.java:339)
at org.openqa.selenium.firefox.FirefoxDriver.toExecutor(FirefoxDriver.java:158)
at org.openqa.selenium.firefox.FirefoxDriver.(FirefoxDriver.java:120)
at org.openqa.selenium.firefox.FirefoxDriver.(FirefoxDriver.java:106)
at com.galenframework.browser.SeleniumBrowserFactory.getDriver(SeleniumBrowserFactory.java:95)
at com.galenframework.browser.SeleniumBrowserFactory.createLocalBrowser(SeleniumBrowserFactory.java:89)
at com.galenframework.browser.SeleniumBrowserFactory.openBrowser(SeleniumBrowserFactory.java:65)
at com.galenframework.runner.GalenBasicTestRunner.runTest(GalenBasicTestRunner.java:73)
at com.galenframework.tests.GalenBasicTest.execute(GalenBasicTest.java:55)
at com.galenframework.TestRunnable.runTest(TestRunnable.java:75)
at com.galenframework.TestRunnable.run(TestRunnable.java:101)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
========================================
========================================
Failed tests:
home.gspec
Suite status: FAIL
Total tests: 1
Total failed tests: 1
Total failures: 1
There were failures in galen tests.
config file is attached
The issue is solved because i added the complete path in the config file :
$.webdriver.gecko.driver=C:/Users/franco.rebuffi/Downloads/geckodriver-v0.22.0-win64/geckodriver.exe
instead of the incomplete path:
$.webdriver.gecko.driver=C:/Users/franco.rebuffi/Downloads/geckodriver-v0.22.0-win64/