= WatirSplash * Web: http://github.com/jarmo/WatirSplash * Author: Jarmo Pertman (mailto:jarmo.p[at]gmail.com) == DESCRIPTION WatirSplash makes browser-based web page testing in Ruby splashin' easy. It combines Watir (http://www.watir.com) for controlling the browser and RSpec (http://relishapp.com/rspec) for testing framework. This powerful combination gives you the ability to write easily well-maintained and easy-to-read specs (specifications in RSpec) so you don't need to have any extra documentation for your applications. WatirSplash makes it easier to use best features of both of these tools together so you won't have to spend time on thinking how to do that yourself - you can start testing right away! == SYNOPSIS === With vanilla Watir and RSpec require 'watir' require 'rspec' describe "Google" do before :all do @browser = Watir::Browser.new @browser.maximize @browser.goto "http://google.com" @browser.url.should =~ /google/ end it "has search field" do text_field = @browser.text_field(:name => "q") text_field.should exist text_field.should be_visible end it "performs search" do @browser.text_field(:name => "q").set "Bing" @browser.button(:name => "btnG").click @browser.text.should include("Bing") end after :all do @browser.close end end === With WatirSplash describe "Google" do before :all do goto "http://google.com" url.should =~ /google/ end it "has search field" do text_field = text_field(:name => "q") text_field.should exist text_field.should be_visible end it "performs search" do text_field(:name => "q").set "Bing" button(:name => "btnG").click text.should include("Bing") end end C:\project\ui-test>rspec spec\google_spec.rb Results will be saved into the directory C:/project/ui-test/results Google has search field performs search Finished in 6.782388 seconds 2 examples, 0 failures == INSTALL 1) install Ruby 2) install WatirSplash: gem install watirsplash 3) execute in your project's directory: watirsplash new == SUPPORTED PLATFORMS & BROWSERS WatirSplash supports different frameworks/browsers on different operating systems: * Linux & OS X - firewatir, watir-webdriver/chrome and watir-webdriver/firefox * Windows - firewatir, watir, watir-webdriver/chrome, watir-webdriver/ie, watir-webdriver/firefox Each framework drives a specific browser: * FireWatir - Firefox * Watir - IE * Watir-WebDriver - Chrome, IE and Firefox It is possible to specify what framework to use in ui-test/config.rb and/or in ui-test-common/config.rb files: WatirSplash::Util.framework = "watir-webdriver/firefox" If framework is not specified manually then a default framework will be used for the current platform. PS! Please note that all frameworks are not 100% compatible with each other. If you find any concrete incompatibilities then it would be great if you'd contribute fixes or information to the authors of the frameworks. == WHAT'S NEXT? You can read more information about the usage and features from the wiki at http://github.com/jarmo/WatirSplash/wiki == COPYRIGHT Copyright © 2010-2011 Jarmo Pertman. See LICENSE for details.