Hello all,
I am having a small issue using the chrome browser with Ruby and the
Watir-webdriver.  Has any one else had this issue?  I cannot figure it out.
 I have it up and running on a Win 7 box but not on my Linux machines.  I
get the same error with both.  I listed it below.  One box is Ubuntu 11.04
and the other is 11.10a.  Also, firefox works fine with the watir-webdriver.
 I have the code commented out below but it works.  It is just chrome that
is not working.  Any ideas?

I am using chrome browser v. 13.0.??? or something like that.  It is a
pretty new version.

<===== code =====>

require 'rubygems'
require 'watir-webdriver'

b = Watir::Browser.new(:chrome)


##### this one works fine #####
# b = Watir::Browser.new(:firefox)

<===== end code =====>

<----- error recieved ----->

Selenium::WebDriver::Error::UnhandledError: Could not find default Chrome
binary
Backtrace:
base::debug::StackTrace::StackTrace() [0x809e79a]
webdriver::Error::Error() [0x807ffe5]
webdriver::Automation::Init() [0x809a8c6]
webdriver::Session::InitOnSessionThread() [0x808da8c]
RunnableMethod<>::Run() [0x808cf0f]
webdriver::Session::RunSessionTaskOnSessionThread() [0x808dc72]
RunnableMethod<>::Run() [0x808c7e1]
base::subtle::TaskClosureAdapter::Run() [0x80ad6f5]
base::internal::Invoker1<>::DoInvoke() [0x80b798e]
MessageLoop::RunTask() [0x80b961f]
MessageLoop::DeferOrRunPendingTask() [0x80b9b5c]
MessageLoop::DoWork() [0x80ba067]
base::MessagePumpDefault::Run() [0x80bd390]
MessageLoop::RunInternal() [0x80b80e4]
MessageLoop::Run() [0x80b814d]
base::Thread::Run() [0x80add8d]
base::Thread::ThreadMain() [0x80ae29e]
base::(anonymous namespace)::ThreadFunc() [0x80adb4c]
start_thread [0xcbed31]
0x1b140ae

from
/usr/lib/ruby/gems/1.8/gems/selenium-webdriver-2.4.0/lib/selenium/webdriver/remote/response.rb:45:in
`assert_ok'
from
/usr/lib/ruby/gems/1.8/gems/selenium-webdriver-2.4.0/lib/selenium/webdriver/remote/response.rb:15:in
`initialize'
from
/usr/lib/ruby/gems/1.8/gems/selenium-webdriver-2.4.0/lib/selenium/webdriver/remote/http/common.rb:53:in
`new'
from
/usr/lib/ruby/gems/1.8/gems/selenium-webdriver-2.4.0/lib/selenium/webdriver/remote/http/common.rb:53:in
`create_response'
from
/usr/lib/ruby/gems/1.8/gems/selenium-webdriver-2.4.0/lib/selenium/webdriver/remote/http/default.rb:56:in
`request'
from
/usr/lib/ruby/gems/1.8/gems/selenium-webdriver-2.4.0/lib/selenium/webdriver/remote/http/common.rb:34:in
`call'
from
/usr/lib/ruby/gems/1.8/gems/selenium-webdriver-2.4.0/lib/selenium/webdriver/remote/bridge.rb:410:in
`raw_execute'
from
/usr/lib/ruby/gems/1.8/gems/selenium-webdriver-2.4.0/lib/selenium/webdriver/remote/bridge.rb:88:in
`create_session'
from
/usr/lib/ruby/gems/1.8/gems/selenium-webdriver-2.4.0/lib/selenium/webdriver/remote/bridge.rb:68:in
`initialize'
from
/usr/lib/ruby/gems/1.8/gems/selenium-webdriver-2.4.0/lib/selenium/webdriver/chrome/bridge.rb:44:in
`initialize'
from
/usr/lib/ruby/gems/1.8/gems/selenium-webdriver-2.4.0/lib/selenium/webdriver/common/driver.rb:35:in
`new'
from
/usr/lib/ruby/gems/1.8/gems/selenium-webdriver-2.4.0/lib/selenium/webdriver/common/driver.rb:35:in
`for'
from
/usr/lib/ruby/gems/1.8/gems/selenium-webdriver-2.4.0/lib/selenium/webdriver.rb:81:in
`for'
from
/usr/lib/ruby/gems/1.8/gems/watir-webdriver-0.3.1/lib/watir-webdriver/browser.rb:35:in
`initialize'
from (irb):3:in `new'
from (irb):3
from  :0irb(main):004:0> ^C



Lastly, I do have a link to google-chrome in the /usr/bin/ folder

-rwxr-xr-x 2 root root 3573 2011-08-03 14:35 google-chrome
-rwxrwxrwx 1 root root 18358264 2011-07-28 09:24 chromedriver
-rwxr-xr-x 2 root root     3573 2011-08-03 14:35 chromium-browser



Kyle

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

[email protected]
http://groups.google.com/group/watir-general
[email protected]

Reply via email to