diff options
author | Kasper Timm Hansen <kaspth@gmail.com> | 2019-02-13 00:44:02 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-02-13 00:44:02 +0100 |
commit | bc2954d02b7bae0c1ae3a9a647d5cf6699c25b51 (patch) | |
tree | acd23f3be831673cb04a49ef847aff6876c47c57 /actioncable/test/subscription_adapter/channel_prefix.rb | |
parent | 7432e251873690234d0d288e8eb009fbee80b635 (diff) | |
parent | 3cd69fa2c025da1cc45b1b9b43b227cceb025837 (diff) | |
download | rails-bc2954d02b7bae0c1ae3a9a647d5cf6699c25b51.tar.gz rails-bc2954d02b7bae0c1ae3a9a647d5cf6699c25b51.tar.bz2 rails-bc2954d02b7bae0c1ae3a9a647d5cf6699c25b51.zip |
Merge pull request #34714 from palkan/chore/refactor-action-cable-server-config
Action Cable: allow multiple instances of Server::Base with different configs
Diffstat (limited to 'actioncable/test/subscription_adapter/channel_prefix.rb')
-rw-r--r-- | actioncable/test/subscription_adapter/channel_prefix.rb | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/actioncable/test/subscription_adapter/channel_prefix.rb b/actioncable/test/subscription_adapter/channel_prefix.rb index 3071facd9d..475e6cfd3a 100644 --- a/actioncable/test/subscription_adapter/channel_prefix.rb +++ b/actioncable/test/subscription_adapter/channel_prefix.rb @@ -2,17 +2,9 @@ require "test_helper" -class ActionCable::Server::WithIndependentConfig < ActionCable::Server::Base - # ActionCable::Server::Base defines config as a class variable. - # Need config to be an instance variable here as we're testing 2 separate configs - def config - @config ||= ActionCable::Server::Configuration.new - end -end - module ChannelPrefixTest def test_channel_prefix - server2 = ActionCable::Server::WithIndependentConfig.new + server2 = ActionCable::Server::Base.new(config: ActionCable::Server::Configuration.new) server2.config.cable = alt_cable_config server2.config.logger = Logger.new(StringIO.new).tap { |l| l.level = Logger::UNKNOWN } |