Hi there,
I just installed a fresh copy of ruby 1.8.7 on Windows XP SP3 32bits. Install watir.
I used the wikipedia example :
require 'rubygems'
require 'watir/ie'
Watir::Browser.default = 'ie'
b = Watir::Browser.new
b.goto("http://www.google.com")
so far so good, works as expected
now
require 'rubygems'
require 'watir/ie'
Watir::Browser.default = 'firefox'
b = Watir::Browser.new
b.goto("http://www.google.com")
throws an ugly
C:\Documents and Settings\Administrator\Desktop>ruby watir2.rb
C:/Ruby187/lib/ruby/gems/1.8/gems/commonwatir-1.6.5/lib/watir/browser.rb:89:in `
klass': undefined method `singularize' for "Buttons":String (NoMethodError)
from C:/Ruby187/lib/ruby/gems/1.8/gems/firewatir-1.6.5/lib/firewatir/ele
ment_collections.rb:185
from C:/Ruby187/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
`gem_original_require'
from C:/Ruby187/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
`require'
from C:/Ruby187/lib/ruby/gems/1.8/gems/firewatir-1.6.5/lib/firewatir.rb:
29
from (eval):1:in `klass'
from C:/Ruby187/lib/ruby/gems/1.8/gems/commonwatir-1.6.5/lib/watir/brows
er.rb:65:in `eval'
from C:/Ruby187/lib/ruby/gems/1.8/gems/commonwatir-1.6.5/lib/watir/brows
er.rb:89:in `klass'
from C:/Ruby187/lib/ruby/gems/1.8/gems/commonwatir-1.6.5/lib/watir/brows
er.rb:65:in `new'
from watir2.rb:7
It should be mentioned that i have followed the procedure documented there http://watir.com/installation/#win besides, I think it's unrelated but I do have the jssh firefox plugin installed as expected.
what's does this undefined method `singularize' stands for ?
below is some environment info
C:\Documents and Settings\Administrator\Desktop>gem env
RubyGems Environment:
- RUBYGEMS VERSION: 1.3.7
- RUBY VERSION: 1.8.7 (2010-08-16 patchlevel 302) [i386-mingw32]
- INSTALLATION DIRECTORY: C:/Ruby187/lib/ruby/gems/1.8
- RUBY EXECUTABLE: C:/Ruby187/bin/ruby.exe
- EXECUTABLE DIRECTORY: C:/Ruby187/bin
- RUBYGEMS PLATFORMS:
- ruby
- x86-mingw32
- GEM PATHS:
- C:/Ruby187/lib/ruby/gems/1.8
- C:/Documents and Settings/Administrator/.gem/ruby/1.8
- GEM CONFIGURATION:
- :update_sources => true
- :verbose => true
- :benchmark => false
- :backtrace => false
- :bulk_threshold => 1000
- REMOTE SOURCES:
- http://rubygems.org/
C:\Documents and Settings\Administrator\Desktop>gem list
*** LOCAL GEMS ***
activesupport (3.0.0)
builder (2.1.2)
commonwatir (1.6.5)
firewatir (1.6.5)
hoe (2.6.1)
json_pure (1.4.6)
nokogiri (1.4.3.1 x86-mingw32)
rake (0.8.7)
rubyforge (2.0.4)
s4t-utils (1.0.4)
user-choices (1.1.6.1)
watir (1.6.5)
win32-api (1.4.6 x86-mingw32)
win32-process (0.6.2)
windows-api (0.4.0)
windows-pr (1.0.9)
xml-simple (1.0.12)
C:\Documents and Settings\Administrator\Desktop>