Sauce OnDemand is a Selenium testing cloud service, developed by Sauce Labs Inc (saucelabs.com). This is the Ruby client adapter for Sauce OnDemand.
Go to file
R. Tyler Croy e66b31f9f5 Use the SSL version of rubygems 2013-03-10 15:16:24 -07:00
bin Refactor the sauce-connect code out into a separate sauce-connect.gem 2013-01-08 22:56:39 -08:00
examples Move the cucumber code out into it's own gem 2012-08-14 21:28:33 -07:00
gemfiles Removed the std gemfile (Simply rely on the root file) 2013-03-06 17:07:21 -08:00
gems updating github links to use the new repo 2013-02-26 18:51:39 -08:00
generators/sauce Whoops...got my logic inverted 2011-03-24 16:11:48 -07:00
lib Made aliasing conditional on Capybara version. 2013-03-08 11:45:18 -08:00
spec Made aliasing conditional on Capybara version. 2013-03-08 11:45:18 -08:00
support updating to the latest Sauce Connect 2013-03-07 23:20:45 -08:00
.document
.gitignore Ignore some Rails cruft in the examples directory 2012-05-24 20:14:27 -07:00
.travis.yml Removed the std gemfile (Simply rely on the root file) 2013-03-06 17:07:21 -08:00
Gemfile Use the SSL version of rubygems 2013-03-10 15:16:24 -07:00
LICENSE updating copyright for 2013 2013-02-26 18:42:53 -08:00
README.markdown fixing another link 2013-02-26 19:19:07 -08:00
Rakefile support newer rdoc/task instead as well as obsolete rake/rdoctask 2013-01-18 14:32:45 -08:00
sauce.gemspec Maybe this? 2013-03-06 16:02:43 -08:00

README.markdown

Sauce for Ruby

Build Status

This is the Ruby client adapter for testing with Sauce Labs, a Selenium-based browser testing service.

There is more information on the wiki, so be sure to look there for information too!

Installation

    % gem install sauce

Suggested Toolchain

The Sauce gem has been optimized to work most effectively with Cucumber and Capybara.

To get started with Sauce and Cucumber, install the appropriate gem:

    % gem install sauce-cucumber

And then read more how to get started with Cucumber and Capybara on this wiki page.

Running on against a list of browsers

To run against a list of browsers, you need to configure them:

Sauce.config do |c|
  c.browsers = [
    ["windows","firefox","18"],
    ["windows","opera","11"]
  ]
end

Then, depending on your test framework:

RSpec 2

Place your specs in the spec/selenium folder

RSpec 1

Give your tests a :type of :selenium, eg describe Aioli, :type => :selenium do

Tests will be run against each combination, sequentially and automagically.

Contributing to the Gem

  • Fork the GitHub project
  • Create a branch to perform your work in, this will help make your pull request more clear.
  • Write some RSpec tests to demonstrate your desired capability or exhibit the bug you're fixing.
  • Make your feature addition or bug fix.
  • Commit
  • Send a pull request! :)

Testing the Gem

Running the full test suite will require RVM

  • Set SAUCE_USERNAME and SAUCE_ACCESS_KEY in your environment to valid Sauce credentials or create an ondemand.yml in the following format:

      access_key: <yourkeyhere>
      username: <yourusernamehere>
    
  • Invoke bundle install to install the gems necessary to work with the Sauce gem

  • Running rake spec:unit will run the RSpec unit tests

  • If you'd like to run the entire test suit, rake test will run all the integration tests, but requires the Sauce credentials to be set up properly as these tests will run actual jobs on Sauce.