hi
I have installed Ruby 1.8.5-21 and also installed the watir 1.5.0 gem.
when i use the run the below program
Operating Systems :Windows XP
i get the below error.Code:require 'watir' #i get the below error # use watir gem test_site = 'http://www.google.com' # set a variable ie =Watir::IE.new # open the IE browser ie.goto(test_site) # load url, go to site ie.text_field(:name, "q").set("pickaxe") # load text "pickaxe" into search field named "q" ie.button(:name, "btnG").click # "btnG" is the name of the Search button, click it if ie.text.include?("Programming Ruby") puts "Test Passed. Found the test string: 'Programming Ruby'." else puts "Test Failed! Could not find: 'Programming Ruby'" end
./watir.rb:4: uninitialized constant Watir (NameError)
from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require'
from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `require'
from watir.rb:2
>Exit code: 1
please tell me how to prevent this error.
Thanks in Advance
K Sathya Narayanan




Bookmarks