2017-10-13 116 views
0

我想将我的项目从Selenium 3.0.0beta4升级到3.6.0。我想设置为页面加载超时与试图在Selenium中设置pageloadtimeout时崩溃3.6

driver.manage().timeouts().pageLoadTimeout(90, TimeUnit.SECONDS); 

然而,这崩溃的应用程序:

Exception in thread "main" org.openqa.selenium.InvalidArgumentException: 
Build info: version: '3.6.0', revision: '6fbf3ec767', time: '2017-09-27T16:15:26.402Z' 
System info: host: 'machine.example.org', ip: '127.0.0.1', os.name: 'Linux', os.arch: 'amd64', os.version: '4.4.88', java.version: '1.8.0_144' 
Driver info: org.openqa.selenium.firefox.FirefoxDriver 
Capabilities [{moz:profile=/tmp/rust_mozprofile.AZHGaB47hL8x, rotatable=false, timeouts={implicit=0, page load=300000, script=30000}, pageLoadStrategy=normal, platform=LINUX, specificationLevel=0, moz:accessibilityChecks=false, acceptInsecureCerts=true, browserVersion=52.4.0, platformVersion=4.4.88, moz:processID=10959, browserName=firefox, javascriptEnabled=true, platformName=LINUX}] 

的值不会改变。我使用的是geckodriver v0.18.0和Firefox 52.4.0。 我可以使用的Firefox版本有任何限制吗?

回答

0

在我的应用程序的硒3.0.0beta4版本我设置以下属性为壁虎司机:

System.setProperty("webdriver.gecko.driver", "/path/to/geckodriver"); 

后,我在硒3.6.0改变属性

System.setProperty("webdriver.firefox.marionette", "/path/to/geckodriver"); 

版本我的应用程序又开始工作。我使用Firefox v45.9.0和geckodriver v0.18.0。其他组合也可能起作用。

0

我相信这是版本兼容性。尝试使用Selenium 3.6.0与geckodriver v0.19.0和Firefox 56.0.1。它应该工作正常。

相关问题