Watir::Rack

Gem Version Build Status Coverage

This gem makes Watir work with any Rack App.

Installation

Add this code to your Gemfile:

group :test do
  gem "watir-rack"
end

Usage

Just use Watir like you've always done in your requests/integration tests:

Watir::Rack.app = Hanami.app

browser = Watir::Browser.new
browser.goto home_path
browser.text_field(name: "first").set "Jarmo"
browser.text_field(name: "last").set  "Pertman"
browser.button(name: "sign_in").click

Limitations

  • This is a [quick] adaptation of watir-rails. All the heavy lifting was done by those folks.

Contributors

License

See LICENSE.