• <small id='XKX7I'></small><noframes id='XKX7I'>

  • <legend id='XKX7I'><style id='XKX7I'><dir id='XKX7I'><q id='XKX7I'></q></dir></style></legend>

    <i id='XKX7I'><tr id='XKX7I'><dt id='XKX7I'><q id='XKX7I'><span id='XKX7I'><b id='XKX7I'><form id='XKX7I'><ins id='XKX7I'></ins><ul id='XKX7I'></ul><sub id='XKX7I'></sub></form><legend id='XKX7I'></legend><bdo id='XKX7I'><pre id='XKX7I'><center id='XKX7I'></center></pre></bdo></b><th id='XKX7I'></th></span></q></dt></tr></i><div id='XKX7I'><tfoot id='XKX7I'></tfoot><dl id='XKX7I'><fieldset id='XKX7I'></fieldset></dl></div>

      • <bdo id='XKX7I'></bdo><ul id='XKX7I'></ul>
      1. <tfoot id='XKX7I'></tfoot>
      2. 如何配置量角器 (JS) 以在 Microsoft Edge 中运行测试

        时间:2023-10-12
      3. <small id='hIsMU'></small><noframes id='hIsMU'>

      4. <i id='hIsMU'><tr id='hIsMU'><dt id='hIsMU'><q id='hIsMU'><span id='hIsMU'><b id='hIsMU'><form id='hIsMU'><ins id='hIsMU'></ins><ul id='hIsMU'></ul><sub id='hIsMU'></sub></form><legend id='hIsMU'></legend><bdo id='hIsMU'><pre id='hIsMU'><center id='hIsMU'></center></pre></bdo></b><th id='hIsMU'></th></span></q></dt></tr></i><div id='hIsMU'><tfoot id='hIsMU'></tfoot><dl id='hIsMU'><fieldset id='hIsMU'></fieldset></dl></div>

        1. <legend id='hIsMU'><style id='hIsMU'><dir id='hIsMU'><q id='hIsMU'></q></dir></style></legend>

            • <bdo id='hIsMU'></bdo><ul id='hIsMU'></ul>
                • <tfoot id='hIsMU'></tfoot>
                    <tbody id='hIsMU'></tbody>

                  本文介绍了如何配置量角器 (JS) 以在 Microsoft Edge 中运行测试?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

                  问题描述

                  我想将我的 protractor.conf.js 设置为在 Edge 而不是 Chrome 中运行测试.设置这个

                  I want to set my protractor.conf.js to run tests in Edge instead of in Chrome. Setting this

                  capabilities: {
                      'browserName': 'MicrosoftEdge'
                  }
                  

                  导致 SessionNotCreatedError: Unable to create new service: EdgeDriverService 错误代码为 199.我从 Microsoft 的网站,但我不知道如何告诉 Protractor 在哪里可以找到该驱动程序.我尝试将它添加到我的用户路径、系统路径、量角器节点模块文件夹中的 selenium 文件夹,并给出 jvmArgs:seleniumArgs:['-Dwebdriver.edge.driver="<path-to-driver"'],但我仍然得到那个 SessionNotCreatedError.

                  results in SessionNotCreatedError: Unable to create new service: EdgeDriverService with an error code of 199. I downloaded the MicrosoftWebDriver.exe for the version of Edge that I have from Microsoft's website, but I can't figure out how to tell Protractor where to find that driver. I've tried adding it to my user path, my system path, the selenium folder in protractor's node modules folder, and giving a jvmArgs: or seleniumArgs: of ['-Dwebdriver.edge.driver="<path-to-driver"'], but I still get that SessionNotCreatedError.

                  我只编写纯 JavaScript,而不是 Java 或 C#,我希望将所有这些设置为 protractor.conf.js 文件中的属性,而不是在实际的测试文件中设置任何内容.我拥有最新版本的 Node,并且确保在运行 ng e2e 时关闭 Edge.我需要更改或添加什么到我的配置文件才能让它运行?

                  I'm only writing pure JavaScript, no Java or C#, and I want all of this to be set as attributes in the protractor.conf.js file, nothing set in the actual file of tests. I have the most recent version of Node, and I'm making sure to have Edge closed when running ng e2e. What do I need to change or add to my config file to get this to run?

                  从 这个 github 问题,我添加了 seleniumAddress: http://127.0.01:17556/ 到我的配置文件,但现在我收到 ECONNREFUSED 127.0.0.1:17556 错误,错误代码为 135.我从以下地址之一获得该地址关于该 github 问题的评论,但无论手动启动 Edge 驱动程序还是仅运行 ng e2e --config <path-to-config>,我都会收到相同的错误.

                  From this github issue, I added seleniumAddress: http://127.0.01:17556/ to my config file, but now I'm getting an ECONNREFUSED 127.0.0.1:17556 error with error code 135. I got that address from one of the comments on that github issue, but I get the same error regardless of starting the Edge driver manually or just running ng e2e --config <path-to-config>.

                  解决方案
                  seleniumAddress: 'http://localhost:4444/wd/hub' 添加到配置文件中.使用 webdriver-manager start --edge "MicrosoftWebDriver.exe" 手动运行边缘驱动程序,然后在另一个窗口中运行 ng e2e.非常感谢 HaC 提供的解决方案!

                  SOLUTION
                  Add seleniumAddress: 'http://localhost:4444/wd/hub' to the config file. Run the edge driver manually with webdriver-manager start --edge "<path-to-driver>MicrosoftWebDriver.exe", and then run ng e2e in another window. Thank you so much to HaC for this solution!

                  推荐答案

                  参考:https://github.com/angular/protractor/issues/2377

                  1. 下载并安装 Edge 驱动
                  2. 运行 webdriver-manager start --edge "C:path_to_the_driverMicrosoftWebDriver.exe" .默认情况下,这将在端口 4444 上启动您的 selenium 服务器,该端口应该对您开放.
                  3. 在量角器配置文件中:添加 seleniumAddress: 'http://localhost:4444/wd/hub'
                  1. Download and install Edge driver
                  2. Run webdriver-manager start --edge "C:path_to_the_driverMicrosoftWebDriver.exe" . By default this will start your selenium server on port 4444 which should be open to you.
                  3. In your protractor config file: add seleniumAddress: 'http://localhost:4444/wd/hub'

                  这篇关于如何配置量角器 (JS) 以在 Microsoft Edge 中运行测试?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!

                  上一篇:在数组javascript的排序函数中实现async/await 下一篇:将量角器与 PhantomJS 一起使用

                  相关文章

                  最新文章

                      <bdo id='aF5gF'></bdo><ul id='aF5gF'></ul>

                  1. <i id='aF5gF'><tr id='aF5gF'><dt id='aF5gF'><q id='aF5gF'><span id='aF5gF'><b id='aF5gF'><form id='aF5gF'><ins id='aF5gF'></ins><ul id='aF5gF'></ul><sub id='aF5gF'></sub></form><legend id='aF5gF'></legend><bdo id='aF5gF'><pre id='aF5gF'><center id='aF5gF'></center></pre></bdo></b><th id='aF5gF'></th></span></q></dt></tr></i><div id='aF5gF'><tfoot id='aF5gF'></tfoot><dl id='aF5gF'><fieldset id='aF5gF'></fieldset></dl></div>

                    <tfoot id='aF5gF'></tfoot>
                    1. <legend id='aF5gF'><style id='aF5gF'><dir id='aF5gF'><q id='aF5gF'></q></dir></style></legend>

                      <small id='aF5gF'></small><noframes id='aF5gF'>