Commit 261e4fe8 authored by Robert Speicher's avatar Robert Speicher Committed by Clement Ho

Merge branch 'dm-restore-capybara-screenshot' into 'master'

Don't reset the session when the example failed to fix capybara-screenshot

See merge request !12370
parent 99ea7188
......@@ -36,12 +36,13 @@ RSpec.configure do |config|
$capybara_server_already_started = true
config.after(:each, :js) do
config.after(:each, :js) do |example|
# capybara/rspec already calls Capybara.reset_sessions! in an `after` hook,
# but `block_and_wait_for_requests_complete` is called before it so by
# calling it explicitely here, we prevent any new requests from being fired
# See
# We don't reset the session when the example failed, because we need capybara-screenshot to have access to it.
Capybara.reset_sessions! unless example.exception
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment