5

SeleniumRubyWindowsTest.rb:1:in `require': no such file to load -- selenium (Loa dError) from SeleniumRubyWindowsTest.rb:1

I followed the steps from this blog - http://testnerdy.blogspot.ca/2009/10/installing-ruby-and-selenium-on-windows.html

This blog is a little dated, so I am assuming it has to do with that. Anyone have any ideas on what I may be doing wrong?

Code as requested (this is copy/pasted from http://testnerdy.blogspot.ca/2009/10/running-selenium-tests-written-in-ruby.html)

require "selenium"
require "test/unit"

class SeleniumRubyWindowsTest < Test::Unit::TestCase
  def setup
    @verification_errors = []
    if $selenium
      @selenium = $selenium
    else
      @selenium = Selenium::SeleniumDriver.new("localhost", 4444, "*chrome", "http://www.yahoo.com/", 10000);
      @selenium.start
    end
    @selenium.set_context("SeleniumRubyWindowsTest")
  end

  def teardown
    @selenium.stop unless $selenium
    assert_equal [], @verification_errors
  end

  def test_SeleniumRubyWindowsTest
    @selenium.open "/"
    assert_equal "Yahoo!", @selenium.get_title
    @selenium.type "p_13838465-p", "Selenium RC"
    @selenium.click "search-submit"
    @selenium.wait_for_page_to_load "30000"
    assert_equal "Selenium RC - Yahoo! Search Results", @selenium.get_title
  end
end
Lyndon Vrooman
  • 6,116
  • 26
  • 52
Letstestthisfast
  • 115
  • 1
  • 1
  • 6

1 Answers1

3

Seems my suggestion of doing a gem uninstall and then an install worked

Phil Kirkham
  • 3,577
  • 1
  • 17
  • 15