无法在Firefox中运行量角器测试

时间:2017-04-10 21:08:22

标签: protractor

我在firefox上运行测试时遇到问题

firefox: {
        name: 'Firefox',
        browserName: 'firefox',
        logName: 'Firefox',
        shardTestFiles: true,
        maxInstances: 3
    },
 exports.config = {
      directConnect: true,
      firefoxPath: null,

出现以下错误

[14:28:56] I/direct - Using FirefoxDriver directly...
[14:28:56] I/launcher - Running 1 instances of WebDriver
[14:29:42] E/launcher - Timed out waiting for the WebDriver server at http://127.0.0.1:51681/hub
[14:29:42] E/launcher - Error: Timed out waiting for the WebDriver server at http://127.0.0.1:51681/hub
    at Error (native)
    at onError (C:\QA\testingmaster\tests\protractor_tests\node_modules\protractor\node_modules\selenium-webdriver\http\util.js:87:11)

Firefox浏览器启动但未导航到baseUrl,而是在地址栏中的about:blank&utm_content=firstrun上窒息

我看过几篇建议手动启动selenium-server的帖子。那里有明确的答案吗?

1 个答案:

答案 0 :(得分:0)

使用browserName:'firefox'替换整个firefox:{}。我认为这将解决问题。