<tfoot id='HGDue'></tfoot>

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

      1. <small id='HGDue'></small><noframes id='HGDue'>

          <bdo id='HGDue'></bdo><ul id='HGDue'></ul>
        <legend id='HGDue'><style id='HGDue'><dir id='HGDue'><q id='HGDue'></q></dir></style></legend>

        如何从命令行覆盖 protractor.conf.js 值?

        时间:2023-10-12

        <tfoot id='KVZws'></tfoot>
            <tbody id='KVZws'></tbody>

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

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

                <bdo id='KVZws'></bdo><ul id='KVZws'></ul>
                <legend id='KVZws'><style id='KVZws'><dir id='KVZws'><q id='KVZws'></q></dir></style></legend>

                1. 本文介绍了如何从命令行覆盖 protractor.conf.js 值?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

                  问题描述

                  我目前有量角器设置可以在我们的集成服务器上运行.在 protractor.conf.js 文件中,我有以下内容:

                  I currently have protractor setup to run on our integration server. Inside the protractor.conf.js file i have the following:

                   multiCapabilities: [{
                      'browserName': 'firefox',
                      'platform': 'MAC'
                    }, {
                      'browserName': 'chrome',
                      'platform': 'MAC'
                    }]
                  

                  我想在从命令行本地运行时覆盖它.我试过以下没有成功

                  I would like to override this when running locally from the command line. I've tried the following with no success

                  protractor --verbose --browser=chrome
                  

                  问题:从命令行本地运行时,如何切换到仅使用单个 chrome 实例?

                  Question: How do i switch to only using a single instance of chrome when running locally from the command line?

                  推荐答案

                  这是个问题.

                  根据源码,浏览器 命令行参数是 capabilities.browserName 的别名.

                  According to the source code, browser command line argument is an alias of capabilities.browserName.

                  根据 referenceConf.js 文档:

                  According to the referenceConf.js documentation:

                  // If you would like to run more than one instance of WebDriver on the same
                  // tests, use multiCapabilities, which takes an array of capabilities.
                  // If this is specified, capabilities will be ignored.
                  multiCapabilities: [],
                  

                  换句话说,由于指定了 multiCapabilitiescapabilities 将被忽略.

                  In other words, since multiCapabilities are specified, capabilities are ignored.

                  您可以尝试从命令行重置 multiCapabilities:

                  What you can try to do is to reset multiCapabilities from command-line:

                  protractor --verbose --browser=chrome --multiCapabilities
                  

                  作为另一种解决方法,使用单独的配置文件来运行单个浏览器实例.

                  As an another workaround, have a separate config file for running a single browser instance.

                  另外,相关主题列表:

                  • 添加了对 multiCapabilities 对象和 splitTestsBetweenCapabilities 布尔值的支持
                  • Multicapabilities 规范忽略命令行上的 --specs 标志并继续运行

                  这篇关于如何从命令行覆盖 protractor.conf.js 值?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!

                  上一篇:如何访问量角器测试的 chromedriver 日志 下一篇:如何在量角器上按 Ctrl+单击?

                  相关文章

                  最新文章

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

                    3. <small id='FhhCU'></small><noframes id='FhhCU'>

                    4. <tfoot id='FhhCU'></tfoot>