2016-12-11 35 views
0

只是不能讓它在我的Mac上工作。量角器:OS X:驅動程序可執行文件的路徑必須由webdriver.chrome.driver系統屬性設置

它一直在我的Windows機器上的精細W/T的任何配置的變化等等,但我安裝了它在我的Mac和運行的想法如何得到它的工作

節點版本:3.10.7
量角器版本:版本4.0.13
器瀏覽器:Chrome的
操作系統和版本OS X埃爾卡皮坦
安裝的驅動程序: 在/ usr/local/lib目錄/ node_modules /量角器/ node_modules/webdriver的-經理/硒
和chromedriver_2.25

另外:由https://chromedriver.storage.googleapis.com/index.html?path=2.26/

  • 下載

    • 複製到:在/ usr/local/lib目錄/ node_modules /量角器/ node_modules/webdriver的經理/硒 仍然沒有工作 是有什麼辦法將其設置在conf文件或某個'?

      登錄:

      $量角器conf_basic.js [18時34分22秒] I /託管 - 使用硒服務器在http://localhost:4444/wd/hub [18時34分22秒] I /發射器 - 運行1種的webdriver的情況下, [18:34:23] E/launcher - 驅動程序可執行文件的路徑必須由webdriver.chrome.driver系統屬性設置;有關更多信息,請參閱https://github.com/SeleniumHQ/selenium/wiki/ChromeDriver。最新版本可從http://chromedriver.storage.googleapis.com/index.html [18:34:23]下載E/launcher - WebDriverError:驅動程序可執行文件的路徑必須由webdriver.chrome.driver系統屬性設置;有關更多信息,請參閱https://github.com/SeleniumHQ/selenium/wiki/ChromeDriver。可以從WebDriverError(/usr/local/lib/node_modules/protractor/node_modules/selenium-webdriver/lib/error.js:27:5)處的http://chromedriver.storage.googleapis.com/index.html (位於Object.checkLegacyResponse(/ usr/local/lib/node_modules/protractor/node_modules/selenium-webdriver/lib/error.js:639:15) at parseHttpResponse(/usr/local/lib/node_modules/protractor/node_modules/selenium-webdriver/http/index.js:538 :13) at client_.send.then.response(/usr/local/lib/node_modules/protractor/node_modules/selenium-webdriver/http/index.js:472:11) at ManagedPromise.invokeCallback_(/ usr/local /lib/node_modules/protractor/node_modules/selenium-webdriver/lib/promise.js:1379:14) at TaskQueue.execute_(/ usr/local/lib/node_modules/protractor/node_modules/selenium-webdriver/lib/promise。 js:2913:14) 在TaskQueue.executeNext_(/usr/local/lib/node_modules/protractor/node_modules/selenium-webdriver/lib/promise.js:2896:21)

    EDIT

    webdriver-manager update --versions.chrome 2.26 
    

    [07:32:45] I/update - selenium standalone:file exists /usr/local/lib/node_modules/protractor/node_modules/webdriver-manager/selenium/selenium-server-standalone-2.53.1.jar [07: 32:45] I/update - selenium standalone:v2.53.1最新版本 [07:32:45] I/update - chromedriver:文件存在/ usr/local/lib/node_modules /或/ node_modules/webdriver的經理/硒/ chromedriver_2.26mac64。拉鍊 [7點32分45秒] I /更新 - chromedriver:解壓chromedriver_2.26mac64.zip [7點32分45秒] I /更新 - chromedriver:設置權限爲0755的在/ usr/local/lib目錄/ node_modules /量角器/ node_modules/webdriver-manager/selenium/chromedriver_2.26 [07:32:45] I/update - chromedriver:v2.26最新版本 [07:32:47] I/update - geckodriver:file exists /usr/local/lib/node_modules/protractor/node_modules/webdriver-manager/selenium/geckodriver-v0.11.1-macos.tar.gz [7點32分47秒] I /更新 - geckodriver:解壓geckodriver-v0.11.1 -macos.tar.gz [7點32分47秒] I /更新 - geckodriver:設置權限,以0755爲/usr/local/lib/node_modules/protractor/node_modules/webdriver-manager/selenium/geckodriver-v0.11.1 [07:32:47]我/更新Ë - geckodriver:vv0.11.1最新

    ,以給它更允許我去:在/ usr/local/lib目錄/ node_modules /量角器/ node_modules/webdriver的經理/硒

    和執行CHMOD 777 chromedriver_2.26

    我做起吧:webdriver的經理開始--versions.chrome 2.26,你告訴我的。仍然沒有喜悅

    [07:38:11] I/start - java -Dwebdriver.chrome.driver=/usr/local/lib/node_modules/protractor/node_modules/webdriver-manager/selenium/chromedriver_2.26 -Dwebdriver.gecko.driver=/usr/local/lib/node_modules/protractor/node_modules/webdriver-manager/selenium/geckodriver-v0.11.1 -jar /usr/local/lib/node_modules/protractor/node_modules/webdriver-manager/selenium/selenium-server-standalone-2.53.1.jar -port 4444 [07:38:11] I/start - seleniumProcess.pid: 509 07:38:12.779 INFO - Launching a standalone Selenium Server 07:38:12.887 INFO - Java: Oracle Corporation 25.101-b13 07:38:12.887 INFO - OS: Mac OS X 10.11.6 x86_64 07:38:12.965 INFO - v2.53.1, with Core v2.53.1. Built from revision a36b8b1 07:38:13.106 INFO - Driver provider org.openqa.selenium.ie.InternetExplorerDriver registration is skipped: registration capabilities Capabilities [{ensureCleanSession=true, browserName=internet explorer, version=, platform=WINDOWS}] does not match the current platform MAC 07:38:13.107 INFO - Driver provider org.openqa.selenium.edge.EdgeDriver registration is skipped: registration capabilities Capabilities [{browserName=MicrosoftEdge, version=, platform=WINDOWS}] does not match the current platform MAC 07:38:13.107 INFO - Driver class not found: com.opera.core.systems.OperaDriver 07:38:13.107 INFO - Driver provider com.opera.core.systems.OperaDriver is not registered 07:38:13.110 INFO - Driver class not found: org.openqa.selenium.htmlunit.HtmlUnitDriver 07:38:13.110 INFO - Driver provider org.openqa.selenium.htmlunit.HtmlUnitDriver is not registered 07:38:13.368 INFO - RemoteWebDriver instances should connect to: http://127.0.0.1:4444/wd/hub 07:38:13.368 INFO - Selenium Server is up and running

    SOLUTION

    1. 須藤量角器cons.js OR
    2. 下載chromedriver並將其複製到USR/local/bin目錄
  • 回答

    2

    我猜你正在啓動webdriver-manager來啓動你的硒獨立服務器。你需要做的是運行webdriver-manager update --versions.chrome 2.26。然後,在啓動硒獨立服務器時,您將運行webdriver-manager start --versions.chrome 2.26

    +0

    它沒有幫助,壽2.26下載並提取到chromedriver_2.26 – rafalf

    +0

    如果你是做手工,你改變訪問權限chromedriver_2.26?另外,如果您手動執行所有這些操作,您將如何啓動獨立服務器? – cnishina

    +0

    我編輯了我的帖子,詳細說明了如何運行它。 – rafalf

    相關問題