aboutsummaryrefslogtreecommitdiffstats
path: root/actioncable
diff options
context:
space:
mode:
authorMatthew Draper <matthew@trebex.net>2016-10-02 11:01:30 +1030
committerMatthew Draper <matthew@trebex.net>2016-10-02 12:25:33 +1030
commita5abc310cdcf282444dc0a43788a62e857d3f2c9 (patch)
tree7cdc31c50795e18f25eb51bb5d0f90ec545fa845 /actioncable
parent53ede1aff2025d4391d0e05ba471fdaf3110a99c (diff)
downloadrails-a5abc310cdcf282444dc0a43788a62e857d3f2c9.tar.gz
rails-a5abc310cdcf282444dc0a43788a62e857d3f2c9.tar.bz2
rails-a5abc310cdcf282444dc0a43788a62e857d3f2c9.zip
Shut down EventMachine before re-enabling warnings
Diffstat (limited to 'actioncable')
-rw-r--r--actioncable/test/subscription_adapter/common.rb1
-rw-r--r--actioncable/test/subscription_adapter/evented_redis_test.rb8
2 files changed, 9 insertions, 0 deletions
diff --git a/actioncable/test/subscription_adapter/common.rb b/actioncable/test/subscription_adapter/common.rb
index ee62b9c088..8cf0b5c684 100644
--- a/actioncable/test/subscription_adapter/common.rb
+++ b/actioncable/test/subscription_adapter/common.rb
@@ -11,6 +11,7 @@ module CommonSubscriptionAdapterTest
def setup
server = ActionCable::Server::Base.new
server.config.cable = cable_config.with_indifferent_access
+ server.config.logger = Logger.new(StringIO.new).tap { |l| l.level = Logger::UNKNOWN }
adapter_klass = server.config.pubsub_adapter
diff --git a/actioncable/test/subscription_adapter/evented_redis_test.rb b/actioncable/test/subscription_adapter/evented_redis_test.rb
index d6ca0e77cb..f316bc46ef 100644
--- a/actioncable/test/subscription_adapter/evented_redis_test.rb
+++ b/actioncable/test/subscription_adapter/evented_redis_test.rb
@@ -12,6 +12,14 @@ class EventedRedisAdapterTest < ActionCable::TestCase
end
def teardown
+ super
+
+ # Ensure EM is shut down before we re-enable warnings
+ EventMachine.reactor_thread.tap do |thread|
+ EventMachine.stop
+ thread.join
+ end
+
$VERBOSE = @previous_verbose
end