aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_dispatch/testing/integration.rb
diff options
context:
space:
mode:
authorJorge Bejar and Santiago Pastorino <jorge+santiago@wyeworks.com>2016-03-02 16:30:52 -0300
committerJorge Bejar and Santiago Pastorino <jorge+santiago@wyeworks.com>2016-03-02 16:44:10 -0300
commitcf075d9f55047281a5912e1b28cc4cb4bfcfdbf0 (patch)
tree5fe1e3b1fce898ba2f450d50f4cc59f7547d57de /actionpack/lib/action_dispatch/testing/integration.rb
parent4f21ac7e9c3a2a21f7fc9ac0d8a0be0c0c7525a2 (diff)
downloadrails-cf075d9f55047281a5912e1b28cc4cb4bfcfdbf0.tar.gz
rails-cf075d9f55047281a5912e1b28cc4cb4bfcfdbf0.tar.bz2
rails-cf075d9f55047281a5912e1b28cc4cb4bfcfdbf0.zip
Do not run app.executor callbacks in integration tests
This reverts changes made to integration tests in PR #23807. The issue happens when using capybara with a driver that needs to start a server in a separate thread like (poltergeist, selenium, etc). Both threads the capybara server one and the test thread end running syncronize over the interlock.
Diffstat (limited to 'actionpack/lib/action_dispatch/testing/integration.rb')
-rw-r--r--actionpack/lib/action_dispatch/testing/integration.rb13
1 files changed, 2 insertions, 11 deletions
diff --git a/actionpack/lib/action_dispatch/testing/integration.rb b/actionpack/lib/action_dispatch/testing/integration.rb
index e871ddd289..f4534b4173 100644
--- a/actionpack/lib/action_dispatch/testing/integration.rb
+++ b/actionpack/lib/action_dispatch/testing/integration.rb
@@ -455,24 +455,17 @@ module ActionDispatch
def before_setup # :nodoc:
@app = nil
@integration_session = nil
- @execution_context = nil
- super
- end
-
- def after_teardown # :nodoc:
- remove!
super
end
def integration_session
- @integration_session ||= create_session(app).tap { @execution_context = app.respond_to?(:executor) && app.executor.run! }
+ @integration_session ||= create_session(app)
end
# Reset the current session. This is useful for testing multiple sessions
# in a single test case.
def reset!
- remove!
- integration_session
+ @integration_session = create_session(app)
end
def create_session(app)
@@ -488,8 +481,6 @@ module ActionDispatch
end
def remove! # :nodoc:
- @execution_context.complete! if @execution_context
- @execution_context = nil
@integration_session = nil
end