<bdo id='vR3Tz'></bdo><ul id='vR3Tz'></ul>
    1. <small id='vR3Tz'></small><noframes id='vR3Tz'>

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

      <tfoot id='vR3Tz'></tfoot>

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

        禁用 Chrome 通知 (Selenium)

        Disable Chrome notifications (Selenium)(禁用 Chrome 通知 (Selenium))
      2. <tfoot id='AlfxY'></tfoot>
        <legend id='AlfxY'><style id='AlfxY'><dir id='AlfxY'><q id='AlfxY'></q></dir></style></legend>
          <tbody id='AlfxY'></tbody>

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

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

                  本文介绍了禁用 Chrome 通知 (Selenium)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  我只想在 Selenium Java 应用程序打开的 Chrome 中禁用 Chrome 通知.(使用java代码)

                  I just want to disable Chrome notifications in the Chrome opened by a Selenium Java application. (using java code)

                  类似这样的通知:

                  问题是关闭浏览器窗口后手动设置的设置会丢失.

                  The problem is that settings manually set are lost after browser's window is closed.

                  推荐答案

                  此问题已在chromedriver-users"谷歌论坛中得到解答.这是有效的答案:

                  This question was answered in the: "chromedriver-users" google forum. This is the working answer:

                  Map<String, Object> prefs = new HashMap<String, Object>();
                  prefs.put("profile.default_content_setting_values.notifications", 2);
                  ChromeOptions options = new ChromeOptions();
                  options.setExperimentalOption("prefs", prefs);
                  WebDriver driver = new ChromeDriver(options);
                  

                  这篇关于禁用 Chrome 通知 (Selenium)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                  相关文档推荐

                  How to send data to COM PORT using JAVA?(如何使用 JAVA 向 COM PORT 发送数据?)
                  How to make a report page direction to change to quot;rtlquot;?(如何使报表页面方向更改为“rtl?)
                  Use cyrillic .properties file in eclipse project(在 Eclipse 项目中使用西里尔文 .properties 文件)
                  Is there any way to detect an RTL language in Java?(有没有办法在 Java 中检测 RTL 语言?)
                  How to load resource bundle messages from DB in Java?(如何在 Java 中从 DB 加载资源包消息?)
                  How do I change the default locale settings in Java to make them consistent?(如何更改 Java 中的默认语言环境设置以使其保持一致?)

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

                  <tfoot id='q5S8G'></tfoot>

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

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