2017-03-03 95 views
2

IRB我做了以下內容:硒:: webdriver的::錯誤:: WebDriverError:無法連接到chromedriver

require "watir" 
b = Watir::Browser.new :chrome 

然後我得到以下錯誤:

Selenium::WebDriver::Error::WebDriverError: unable to connect to chromedriver 127.0.0.1:9515 

OSX 10.12.3 Ruby 2.3.1 Chrome驅動程序最新版本 Watir 6.2.0

+1

你需要下載驅動程序,請參閱http://stackoverflow.com/questions/27719345/how-to-specify-the-location-of-the-chromedriver-binary –

+2

你可以'gem install webdrivers'和它將自動使您的系統保持最新版本的任何驅動程序正在使用 – titusfortner

回答

1
gem install webdrivers

爲我工作。

相關問題