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

      <tfoot id='Izoxi'></tfoot>

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

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

      1. 如何访问量角器测试的 chromedriver 日志

        时间:2023-10-12
          <bdo id='tTKdI'></bdo><ul id='tTKdI'></ul>
            <tbody id='tTKdI'></tbody>
          <tfoot id='tTKdI'></tfoot>

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

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

                  本文介绍了如何访问量角器测试的 chromedriver 日志的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

                  问题描述

                  我看到 chromedriver 可以输出一个日志文件(https://sites.google.com/a/chromium.org/chromedriver/logging)

                  I have seen that chromedriver can output a logfile (https://sites.google.com/a/chromium.org/chromedriver/logging)

                  此页面显示了如何在直接执行 exe 时进行设置:

                  This page shows how to set this up when executing the exe directly:

                  chromedriver.exe --verbose --log-path=chromedriver.log

                  我不知道如何在 Protractor 中进行设置

                  I cannot figure out how to set this up in Protractor however

                  我目前的protractor.conf.js

                  require('babel/register');
                  
                  exports.config = {
                      framework: 'jasmine2',
                      seleniumServerJar: './node_modules/protractor/selenium/selenium-server-standalone-2.45.0.jar'
                  };
                  

                  来自 @alecxe 的回答如下和 量角器的浏览器设置文档 我尝试添加以下内容(有和没有 --s)但没有明显效果:

                  From @alecxe's answer below and protractor's browser setup docs I tried adding the following (with and without --s) but with no apparent effect:

                      capabilities: {
                          browserName: "chrome",
                          chromeOptions: {
                              args: [
                                  "--verbose",
                                  "--log-path=chromedriver.log"
                              ]
                          }
                      }
                  

                  我还尝试指定一个绝对路径 (log-path=/chromedriver.log),但也没有用.

                  I also tried specifying an absolute path (log-path=/chromedriver.log) which also didn't work.

                  推荐答案

                  您始终可以在一个单独的进程中启动您自己的 chromedriver 实例,并告诉 Protractor 连接到该实例.例如,如果您使用以下命令启动 chromedriver:

                  You can always start up your own instance of chromedriver in a separate process and tell Protractor to connect to that. For example, if you start chromedriver with:

                  chromedriver --port=9515 --verbose --log-path=chromedriver.log

                  然后你可以像这样使用 Protractor 的配置文件:

                  Then you could use a configuration file for Protractor like so:

                     exports.config = {
                       seleniumAddress: 'http://localhost:9515',
                       capabilities: {
                         'browserName': 'chrome'
                       },
                       specs: ['example_spec.js'],
                     };
                  

                  这篇关于如何访问量角器测试的 chromedriver 日志的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!

                  上一篇:“window.angular 未定义."当使用量角器进行自动 下一篇:如何从命令行覆盖 protractor.conf.js 值?

                  相关文章

                  最新文章

                  <legend id='6hMKR'><style id='6hMKR'><dir id='6hMKR'><q id='6hMKR'></q></dir></style></legend>

                1. <small id='6hMKR'></small><noframes id='6hMKR'>

                  • <bdo id='6hMKR'></bdo><ul id='6hMKR'></ul>

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

                    1. <tfoot id='6hMKR'></tfoot>