Browse files

added documentation for Test::Unit integration

  • Loading branch information...
1 parent b7a460c commit 112be586e373be2889e1c8d79faecf5c49891547 @joliss joliss committed Apr 14, 2011
Showing with 13 additions and 2 deletions.
  1. +13 −2 README.rdoc
@@ -138,10 +138,21 @@ Capybara also comes with a built in DSL for creating descriptive acceptance test
Note that Capybara's built in RSpec support only works with RSpec 2.0 or later.
You'll need to roll your own for earlier versions of RSpec.
+== Using Capybara with Test::Unit
+To use Capybara with Test::Unit, include the DSL (<tt>include Capybara</tt> up
+until version 0.4.x, <tt>include Capybara::DSL</tt> for newer versions) in
+whatever test class you are using. For example, if your classes derive from
+<tt>ActionDispatch::IntegrationTest</tt>, use
+ class ActionDispatch::IntegrationTest
+ include Capybara::DSL
+ end
== Using Capybara with Ruby on Rails
-You can use the built-in Rails support to easily get Capybara running with
+If you are using the Rails framework, add this line to automatically configure
+Capybara to test against your Rails application:
require 'capybara/rails'

0 comments on commit 112be58

Please sign in to comment.