lib/action_cable/testing/test_helper.rb in action-cable-testing-0.5.0 vs lib/action_cable/testing/test_helper.rb in action-cable-testing-0.6.0
- old
+ new
@@ -1,7 +1,10 @@
# frozen_string_literal: true
+require "action_cable/testing/rails_six"
+using ActionCable::Testing::Rails6
+
module ActionCable
# Provides helper methods for testing Action Cable broadcasting
module TestHelper
CHANNEL_NOT_FOUND = ArgumentError.new("Broadcasting channel can't be infered. Please, specify it with `:channel`")
@@ -142,10 +145,10 @@
return target if target.is_a?(String)
channel ||= @subscription
return target unless channel && channel.respond_to?(:channel_name)
- channel.broadcasting_for([channel.channel_name, target])
+ channel.broadcasting_for(target)
end
def warn_deprecated_channel!
ActiveSupport::Deprecation.warn(
"Passing channel class is deprecated and will be removed in version 1.0. " \