久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

    <i id='E7rW1'><tr id='E7rW1'><dt id='E7rW1'><q id='E7rW1'><span id='E7rW1'><b id='E7rW1'><form id='E7rW1'><ins id='E7rW1'></ins><ul id='E7rW1'></ul><sub id='E7rW1'></sub></form><legend id='E7rW1'></legend><bdo id='E7rW1'><pre id='E7rW1'><center id='E7rW1'></center></pre></bdo></b><th id='E7rW1'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='E7rW1'><tfoot id='E7rW1'></tfoot><dl id='E7rW1'><fieldset id='E7rW1'></fieldset></dl></div>
    <tfoot id='E7rW1'></tfoot>
    • <bdo id='E7rW1'></bdo><ul id='E7rW1'></ul>
      <legend id='E7rW1'><style id='E7rW1'><dir id='E7rW1'><q id='E7rW1'></q></dir></style></legend>

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

    1. 如何正確設置 Java/Selenium 配置以運行自動化測試

      How to properly set up Java/Selenium configuration to run automated tests?(如何正確設置 Java/Selenium 配置以運行自動化測試?)
      <i id='KuBbs'><tr id='KuBbs'><dt id='KuBbs'><q id='KuBbs'><span id='KuBbs'><b id='KuBbs'><form id='KuBbs'><ins id='KuBbs'></ins><ul id='KuBbs'></ul><sub id='KuBbs'></sub></form><legend id='KuBbs'></legend><bdo id='KuBbs'><pre id='KuBbs'><center id='KuBbs'></center></pre></bdo></b><th id='KuBbs'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='KuBbs'><tfoot id='KuBbs'></tfoot><dl id='KuBbs'><fieldset id='KuBbs'></fieldset></dl></div>
      <tfoot id='KuBbs'></tfoot>
      <legend id='KuBbs'><style id='KuBbs'><dir id='KuBbs'><q id='KuBbs'></q></dir></style></legend>

              • <bdo id='KuBbs'></bdo><ul id='KuBbs'></ul>

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

                  <tbody id='KuBbs'></tbody>
              • 本文介紹了如何正確設置 Java/Selenium 配置以運行自動化測試?的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                問題描述

                我正在嘗試設置 selenium webdriver 以與帶有 Java 的 Browserstack 一起使用以進行自動化測試.我為 Java 安裝了 Selenium,并從 browserstack 的站點 https://www 復制并粘貼了代碼.browserstack.com/automate/java#configure-capabilities 設置一個示例自動化測試.

                I am trying to set up selenium webdriver to work together with Browserstack with Java for automated testing. I installed the Selenium for java and I copied and pasted the code from browserstack's site https://www.browserstack.com/automate/java#configure-capabilities to set up an example automation test.

                我從終端運行了 javac -classpath selenium-server-standalone-2.48.2.jar JavaSample.java(JavaSample.java 是帶有示例測試的 selenium 配置代碼的文件)和我收到以下錯誤:

                I ran javac -classpath selenium-server-standalone-2.48.2.jar JavaSample.java from my terminal (JavaSample.java is the file with the selenium configuration code with the sample test) and I get the following error:

                JavaSample.java:1: error: package org.openqa.selenium does not exist
                import org.openqa.selenium.By;
                                      ^
                JavaSample.java:2: error: package org.openqa.selenium does not exist
                import org.openqa.selenium.Platform;
                                      ^
                JavaSample.java:3: error: package org.openqa.selenium does not exist
                import org.openqa.selenium.WebDriver;
                                      ^
                JavaSample.java:4: error: package org.openqa.selenium does not exist
                import org.openqa.selenium.WebElement;
                                      ^
                JavaSample.java:5: error: package org.openqa.selenium.remote does not exist
                import org.openqa.selenium.remote.DesiredCapabilities;
                                             ^
                JavaSample.java:6: error: package org.openqa.selenium.remote does not exist
                import org.openqa.selenium.remote.RemoteWebDriver;
                                             ^
                JavaSample.java:18: error: cannot find symbol
                DesiredCapabilities caps = new DesiredCapabilities();
                ^
                symbol:   class DesiredCapabilities
                location: class JavaSample
                JavaSample.java:18: error: cannot find symbol
                DesiredCapabilities caps = new DesiredCapabilities();
                                               ^
                symbol:   class DesiredCapabilities
                location: class JavaSample
                JavaSample.java:25: error: cannot find symbol
                WebDriver driver = new RemoteWebDriver(new URL(URL), caps);
                ^
                symbol:   class WebDriver
                location: class JavaSample
                JavaSample.java:25: error: cannot find symbol
                WebDriver driver = new RemoteWebDriver(new URL(URL), caps);
                                       ^
                symbol:   class RemoteWebDriver
                location: class JavaSample
                JavaSample.java:27: error: cannot find symbol
                WebElement element = driver.findElement(By.name("q"));
                ^
                symbol:   class WebElement
                location: class JavaSample
                JavaSample.java:27: error: cannot find symbol
                WebElement element = driver.findElement(By.name("q"));
                                                        ^
                symbol:   variable By
                location: class JavaSample
                

                我不知道該怎么做,因為我只是按照 Browserstack 上的說明進行操作,而且我對 Java 的背景很少.

                I'm not sure how to go about this being as I just followed the instructions on Browserstack and I have very little background in Java.

                推薦答案

                您必須從 Selenium 下載.您可以點擊此處.

                You will have to download the "Selenium Client & WebDriver Language Bindings" for Java from Selenium Downloads. You can download directly by clicking the link here.

                包括下載的 ZIP 文件中存在的所有 JAR 文件.要在 Java 類路徑中包含多個 JAR,您可以查看此處的鏈接.

                Include all the JAR files that are present in the downloaded ZIP file. To include multiple JARs in Java classpath, you can check the link here.

                如果您在本地運行測試,則需要 selenium-server-standalone JAR.執(zhí)行命令 java -jar selenium-server-standalone-2.48.2.jar 將啟動一個 Selenium 服務器,它需要在本地啟動 Selenium 測試.如果您在 BrowserStack 上運行測試,則不需要使用它.

                The selenium-server-standalone JAR is required if you are running your tests locally. Executing the command java -jar selenium-server-standalone-2.48.2.jar will start a Selenium server, which required to launch Selenium tests locally. You need not use it, if you are running tests on BrowserStack.

                還建議使用適用于 Java 的 IDE.最普遍推薦的是 IntelliJ Idea、Eclipse 和 Netbeans.

                Would also recommend using an IDE for Java. The most commonly recommended ones are IntelliJ Idea, Eclipse, and Netbeans.

                這篇關(guān)于如何正確設置 Java/Selenium 配置以運行自動化測試?的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

                【網(wǎng)站聲明】本站部分內(nèi)容來源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問題,如果有圖片或者內(nèi)容侵犯了您的權(quán)益,請聯(lián)系我們刪除處理,感謝您的支持!

                相關(guān)文檔推薦

                How can I detect integer overflow on 32 bits int?(如何檢測 32 位 int 上的整數(shù)溢出?)
                Local variables before return statements, does it matter?(return 語句之前的局部變量,這有關(guān)系嗎?)
                How to convert Integer to int?(如何將整數(shù)轉(zhuǎn)換為整數(shù)?)
                How do I create an int array with randomly shuffled numbers in a given range(如何在給定范圍內(nèi)創(chuàng)建一個隨機打亂數(shù)字的 int 數(shù)組)
                Inconsistent behavior on java#39;s ==(java的行為不一致==)
                Why is Java able to store 0xff000000 as an int?(為什么 Java 能夠?qū)?0xff000000 存儲為 int?)
                • <i id='IPeVt'><tr id='IPeVt'><dt id='IPeVt'><q id='IPeVt'><span id='IPeVt'><b id='IPeVt'><form id='IPeVt'><ins id='IPeVt'></ins><ul id='IPeVt'></ul><sub id='IPeVt'></sub></form><legend id='IPeVt'></legend><bdo id='IPeVt'><pre id='IPeVt'><center id='IPeVt'></center></pre></bdo></b><th id='IPeVt'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='IPeVt'><tfoot id='IPeVt'></tfoot><dl id='IPeVt'><fieldset id='IPeVt'></fieldset></dl></div>

                • <legend id='IPeVt'><style id='IPeVt'><dir id='IPeVt'><q id='IPeVt'></q></dir></style></legend>
                  <tfoot id='IPeVt'></tfoot>

                        <tbody id='IPeVt'></tbody>
                        <bdo id='IPeVt'></bdo><ul id='IPeVt'></ul>

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

                          主站蜘蛛池模板: 日韩免费 | 国产精品久久久久久久久图文区 | 一区二区三区在线免费看 | 日韩精品一区二 | 999www视频免费观看 | 国产日韩一区二区三免费高清 | 久久久久久看片 | 黑人巨大精品欧美一区二区免费 | 国产精品免费观看 | 久久久精品视频免费 | 在线看成人av| 久久精品成人 | 国产精品日日摸夜夜添夜夜av | 国产精品一区二区在线 | 四虎永久免费影院 | 国产综合av | 国产一级视屏 | m豆传媒在线链接观看 | 国产成人免费在线 | 日韩免费中文字幕 | 成人在线视频网 | 久久国产精品视频免费看 | 中文字幕一区二区三区精彩视频 | 亚州精品天堂中文字幕 | 国产视频中文字幕在线观看 | 国产精品美女www爽爽爽 | 日韩不卡在线 | 国产精品一区二区无线 | www.干| 91网站视频在线观看 | 久久精品一 | 国产亚洲一区二区三区 | 日韩高清一区 | 嫩草研究影院 | 成人在线视频网站 | 久久精品一级 | 浴室洗澡偷拍一区二区 | 亚洲国产欧美日韩 | 久久99精品久久久97夜夜嗨 | 久久久久久久av | 婷婷不卡|