New issue 3638 by digsy1...@gmail.com: Firefox driver fails to start with
2.20.0
http://code.google.com/p/selenium/issues/detail?id=3638
Selenium version: 2.20.0
OS: Windows 7
Browser: Firefox
Browser version: 7.0.1
Using the Selenium java example code from the website inside a JUnit test,
I am unable to instantiate a new FirefoxDriver, the line
WebDriver driver = new FirefoxDriver();
throws a WebDriverException with the following stack trace:
org.openqa.selenium.WebDriverException: java.lang.IllegalArgumentException:
timeout must not be less than 1.
Build info: version: '2.20.0', revision: '16008', time: '2012-02-28
15:00:40'
System info: os.name: 'Windows 7', os.arch: 'amd64', os.version: '6.1',
java.version: '1.6.0_27'
Driver info: driver.version: TestDriver
at
org.openqa.selenium.firefox.internal.NewProfileExtensionConnection.start(NewProfileExtensionConnection.java:115)
at
org.openqa.selenium.firefox.FirefoxDriver.startClient(FirefoxDriver.java:187)
at
org.openqa.selenium.remote.RemoteWebDriver.<init>(RemoteWebDriver.java:93)
at org.openqa.selenium.firefox.FirefoxDriver.<init>(FirefoxDriver.java:142)
at org.openqa.selenium.firefox.FirefoxDriver.<init>(FirefoxDriver.java:84)
at com.tessella.sdb.system.TestDriver.testDriver(TestDriver.java:34)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at
org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:81)
at org.junit.runner.JUnitCore.run(JUnitCore.java:130)
at
com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:94)
at
com.intellij.rt.execution.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:192)
at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:64)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:115)
Caused by: java.lang.IllegalArgumentException: timeout must not be less
than 1.
at org.apache.commons.exec.Watchdog.<init>(Watchdog.java:39)
at org.apache.commons.exec.ExecuteWatchdog.<init>(ExecuteWatchdog.java:64)
at
org.openqa.selenium.os.UnixProcess$SeleniumWatchDog.<init>(UnixProcess.java:171)
at org.openqa.selenium.os.UnixProcess.<init>(UnixProcess.java:54)
at org.openqa.selenium.os.CommandLine.<init>(CommandLine.java:39)
at
org.openqa.selenium.firefox.FirefoxBinary.startProfile(FirefoxBinary.java:77)
at org.openqa.selenium.firefox.FirefoxBinary.clean(FirefoxBinary.java:225)
at
org.openqa.selenium.firefox.internal.NewProfileExtensionConnection.start(NewProfileExtensionConnection.java:76)
... 27 more
Anybody have any ideas what's wrong?
Comment #1 on issue 3638 by dawa...@gmail.com: Firefox driver fails to
start with 2.20.0
http://code.google.com/p/selenium/issues/detail?id=3638
Do you have a different version of Apache Commons Exec on your classpath?
If you have the version bundled with selenium, 1.1, that stack trace makes
no sense, but if you have a version of commons-exec cut from before
r949870, this would be the expected behaviour.
In short, make sure you only have apache commons exec 1.1 on your classpath.