Sha256: b70a77b2eb7bb6b70efb128337743344e73fca04d4a8deafd707e1c111d7241e

Contents?: true

Size: 543 Bytes

Versions: 8

Compression:

Stored size: 543 Bytes

Contents

require 'spec_helper'

RSpec.shared_examples_for 'a realtime socket' do
  let(:url) { 'wss://ms174.slack-msgs.com/websocket/xyz' }
  let(:logger) { ::Logger.new($stdout) }
  let(:socket) { described_class.new(url, ping: 42, logger: logger) }
  describe '#initialize' do
    it 'sets url' do
      expect(socket.url).to eq url
    end
  end
  describe 'api' do
    [:start_sync, :start_sync, :disconnect!, :connect!, :connected?, :send_data, :close].each do |m|
      it m do
        expect(socket).to respond_to(m)
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
slack-ruby-client-0.10.0 spec/slack/real_time/concurrency/it_behaves_like_a_realtime_socket.rb
slack-ruby-client-0.9.1 spec/slack/real_time/concurrency/it_behaves_like_a_realtime_socket.rb
slack-ruby-client-0.9.0 spec/slack/real_time/concurrency/it_behaves_like_a_realtime_socket.rb
slack-ruby-client-0.8.1 spec/slack/real_time/concurrency/it_behaves_like_a_realtime_socket.rb
slack-ruby-client-0.8.0 spec/slack/real_time/concurrency/it_behaves_like_a_realtime_socket.rb
slack-ruby-client-0.7.9 spec/slack/real_time/concurrency/it_behaves_like_a_realtime_socket.rb
slack-ruby-client-0.7.8 spec/slack/real_time/concurrency/it_behaves_like_a_realtime_socket.rb
slack-ruby-client-0.7.7 spec/slack/real_time/concurrency/it_behaves_like_a_realtime_socket.rb