Sha256: ab2d5425450c89fdbab8b7c32b4c2ab6f1aee73ca551762a650eaa53315feb17

Contents?: true

Size: 998 Bytes

Versions: 4

Compression:

Stored size: 998 Bytes

Contents

require 'rubygems'
require "selenium/client"
require 'rspec'
require 'testingbot'
#require 'testingbot/tunnel'

# rspec 2
describe "People", :type => :selenium do
  attr_reader :selenium_driver
    before(:all) do
        #TestingBot::Tunnel.start_tunnel("selenium@tunnel.testingbot.com", 2052)

        @selenium_driver = Selenium::Client::Driver.new \
            :host => "hub.testingbot.com",
            :port => 4444, 
            :browser => "firefox", 
            :url => "http://www.google.com", 
            :timeout_in_second => 60,
            :platform => "WINDOWS",
            :version => "10"
    end
  
    before(:each) do
      @selenium_driver.start_new_browser_session
    end
  
    after(:each) do
      @selenium_driver.close_current_browser_session
    end
      
    it "can find the right title" do    
      @selenium_driver.open "/"
      @selenium_driver.title.should eql("Google")   
    end

    # after(:all) do
    #   TestingBot::Tunnel.stop_tunnel
    # end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
testingbot-0.0.9 examples/test_rspec.rb
testingbot-0.0.8 examples/test_rspec.rb
testingbot-0.0.7 examples/test_rspec.rb
testingbot-0.0.6 examples/test_rspec.rb