Sha256: b4e197ba041a9da29d66a25c38df95b9c4a295d8681f2a4acff344a2142469a8

Contents?: true

Size: 723 Bytes

Versions: 24

Compression:

Stored size: 723 Bytes

Contents

require 'helper'

class TestConnect < Test::Unit::TestCase
  context "Sauce Connect" do
    should "be running when ready" do
      connect = Sauce::Connect.new(:host => "saucelabs.com", :port => 80)
      assert_equal "uninitialized", connect.status
      connect.wait_until_ready
      assert_equal "running", connect.status 
      connect.status.should == "running"
      connect.disconnect
    end

    should "set error flag if things don't go well" do
      connect = Sauce::Connect.new(:host => "saucelabs.com", :port => 80, :username => 'fail')
      start = Time.now
      while Time.now-start < 20 && !connect.error
        sleep 1
      end

      assert connect.error
      connect.disconnect
    end
  end
end

Version data entries

24 entries across 24 versions & 1 rubygems

Version Path
sauce-0.14.2 test/test_connect.rb
sauce-0.14.1 test/test_connect.rb
sauce-0.14.0 test/test_connect.rb
sauce-0.13.2 test/test_connect.rb
sauce-0.13.1 test/test_connect.rb
sauce-0.13.0 test/test_connect.rb
sauce-0.12.10 test/test_connect.rb
sauce-0.12.9 test/test_connect.rb
sauce-0.12.8 test/test_connect.rb
sauce-0.12.7 test/test_connect.rb
sauce-0.12.6 test/test_connect.rb
sauce-0.12.5 test/test_connect.rb
sauce-0.12.4 test/test_connect.rb
sauce-0.12.3 test/test_connect.rb
sauce-0.12.2 test/test_connect.rb
sauce-0.12.1 test/test_connect.rb
sauce-0.12.0 test/test_connect.rb
sauce-0.11.3 test/test_connect.rb
sauce-0.11.2 test/test_connect.rb
sauce-0.11.1 test/test_connect.rb