Permalink
Browse files

Moved session cleanup to before the test so that i still have browser…

… state when debuging a faild test, (I reuse the Selenuium/Firefox instance by starting it in the prefork part of spork)
  • Loading branch information...
1 parent a4ed172 commit 2cfb73320fb64f189e57f15b681b48ac03608bce @bjornblomqvist bjornblomqvist committed Sep 8, 2011
Showing with 2 additions and 5 deletions.
  1. +2 −5 lib/capybara/cucumber.rb
View
7 lib/capybara/cucumber.rb
@@ -3,8 +3,9 @@
World(Capybara)
-After do
+Before do
Capybara.reset_sessions!
+ Capybara.use_default_driver
end
Before('@javascript') do
@@ -26,7 +27,3 @@
Before('@rack_test') do
Capybara.current_driver = :rack_test
end
-
-After do
- Capybara.use_default_driver
-end

0 comments on commit 2cfb733

Please sign in to comment.