Methods

Instance Public methods

connection_class()

📝 Source code
# File actioncable/lib/action_cable/connection/test_case.rb, line 170
          def connection_class
            if connection = self._connection_class
              connection
            else
              tests determine_default_connection(name)
            end
          end
🔎 See on GitHub

determine_default_connection(name)

📝 Source code
# File actioncable/lib/action_cable/connection/test_case.rb, line 178
          def determine_default_connection(name)
            connection = determine_constant_from_test_name(name) do |constant|
              Class === constant && constant < ActionCable::Connection::Base
            end
            raise NonInferrableConnectionError.new(name) if connection.nil?
            connection
          end
🔎 See on GitHub

tests(connection)

📝 Source code
# File actioncable/lib/action_cable/connection/test_case.rb, line 159
          def tests(connection)
            case connection
            when String, Symbol
              self._connection_class = connection.to_s.camelize.constantize
            when Module
              self._connection_class = connection
            else
              raise NonInferrableConnectionError.new(connection)
            end
          end
🔎 See on GitHub