1
0
Fork 0
mirror of https://github.com/teamcapybara/capybara.git synced 2022-11-09 12:08:07 -05:00

Better documentation for temporary driver switching

This commit is contained in:
Jo Liss 2011-04-02 17:57:55 +02:00
parent 123cd3bd4a
commit 49a9f17136

View file

@ -175,8 +175,9 @@ tests that require a JavaScript-capable driver using <tt>:js => true</tt> or
You can also change the driver temporarily (typically in the Before and After
blocks):
Capybara.current_driver = :culerity
Capybara.use_default_driver
Capybara.current_driver = :culerity # temporarily select different driver
... tests ...
Capybara.use_default_driver # switch back to default driver
Note that switching the driver creates a new session, so you may not be able to
switch in the middle of a test.