aboutsummaryrefslogtreecommitdiffstats
path: root/actioncable/test/connection/identifier_test.rb
diff options
context:
space:
mode:
authorJon Moss <me@jonathanmoss.me>2016-01-16 10:33:50 -0500
committerJon Moss <me@jonathanmoss.me>2016-01-18 19:37:25 -0500
commitae31da20cd250154c951b67d5625fc71ac27e2f1 (patch)
tree8f9bf6275f9e52c3b8a8b674d0bfd2a941f5bdf9 /actioncable/test/connection/identifier_test.rb
parent980e01eb100b38e39791f7f930a038ecaf7c02da (diff)
downloadrails-ae31da20cd250154c951b67d5625fc71ac27e2f1.tar.gz
rails-ae31da20cd250154c951b67d5625fc71ac27e2f1.tar.bz2
rails-ae31da20cd250154c951b67d5625fc71ac27e2f1.zip
Fix code review comments
- adapter -> pubsub (re)rename internally - Change variable names to match method names - Add EventMachine `~> 1.0` as a runtime dependency of ActionCable - Refactor dependency loading for adapters
Diffstat (limited to 'actioncable/test/connection/identifier_test.rb')
-rw-r--r--actioncable/test/connection/identifier_test.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/actioncable/test/connection/identifier_test.rb b/actioncable/test/connection/identifier_test.rb
index bdc793e56d..a110dfdee0 100644
--- a/actioncable/test/connection/identifier_test.rb
+++ b/actioncable/test/connection/identifier_test.rb
@@ -23,12 +23,12 @@ class ActionCable::Connection::IdentifierTest < ActionCable::TestCase
test "should subscribe to internal channel on open and unsubscribe on close" do
run_in_eventmachine do
- adapter = mock('adapter')
- adapter.expects(:subscribe).with('action_cable/User#lifo', kind_of(Proc))
- adapter.expects(:unsubscribe).with('action_cable/User#lifo', kind_of(Proc))
+ pubsub = mock('pubsub_adapter')
+ pubsub.expects(:subscribe).with('action_cable/User#lifo', kind_of(Proc))
+ pubsub.expects(:unsubscribe).with('action_cable/User#lifo', kind_of(Proc))
server = TestServer.new
- server.stubs(:adapter).returns(adapter)
+ server.stubs(:pubsub).returns(pubsub)
open_connection server: server
close_connection