首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >从selenium 3 beta 2迁移到新版本时,Firefox停止工作

从selenium 3 beta 2迁移到新版本时,Firefox停止工作
EN

Stack Overflow用户
提问于 2016-10-29 02:44:36
回答 1查看 308关注 0票数 0

当我尝试从selenium 3 beta-2升级到任何新版本时,Firefox停止工作。我尝试过selenium 3 beta3和4以及selenium 3.0.1

我使用的是:Firefox48.0.2,我还尝试了Firefox49.0.2 Geckodriver v0.10.0 Selenium 3.0.1,我还尝试了Selenium 3 beta3和beta 4 Windows7机器。我的项目是使用maven。

这是我在测试尝试启动firefox时得到的错误消息。

org.openqa.selenium.net.PortProber.waitForPortUp(IILjava/util/concurrent/TimeUnit :java.lang.NoSuchMethodError

当我恢复到Selenium 3beta2时,一切工作正常。

EN

回答 1

Stack Overflow用户

发布于 2016-11-12 06:05:29

花了几个小时寻找答案。我发现如果在pom文件中使用maven项目和selenium 3.0.1依赖项,就会出现这个问题。

我的变通方法是在pom文件中添加Selenium firefox依赖项和selenium服务器依赖项。

在他们发布selenium 3.0.2之前,这种解决方法是暂时的

代码语言:javascript
复制
<!-- https://mvnrepository.com/artifact/org.seleniumhq.selenium/selenium-java -->
    <dependency>
        <groupId>org.seleniumhq.selenium</groupId>
        <artifactId>selenium-java</artifactId>
        <version>3.0.1</version>
    </dependency>

    <!-- https://mvnrepository.com/artifact/org.seleniumhq.selenium/selenium-firefox-driver -->
    <dependency>
        <groupId>org.seleniumhq.selenium</groupId>
        <artifactId>selenium-firefox-driver</artifactId>
        <version>3.0.1</version>
    </dependency>
票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/40311374

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档