Sha256: a2a0913705b4ca786e49a8f4db5d8681ba00ba5728ae54850333844c7d37ba98

Contents?: true

Size: 811 Bytes

Versions: 1

Compression:

Stored size: 811 Bytes

Contents

RSpec.describe Washbullet::API::Subscriptions do
  let(:client) { Washbullet::Client.new(test_api_key) }

  describe '#subscriptions', :vcr do
    subject(:subscriptions) { client.subscriptions }

    specify 'Get list subscriptions' do
      expect(subscriptions.first).to be_kind_of(Washbullet::Channel)
    end
  end

  describe '#channel_info', :vcr do
    subject(:channel_info) { client.channel_info(tag) }

    context 'when channel is existing' do
      let(:tag) { 'docs-hrysd-org' }

      specify 'Get information about a channel' do
        expect(channel_info).to be_kind_of(Washbullet::Channel)
      end
    end

    context 'when channel is not existing' do
      let(:tag) { 'invalid' }

      specify 'raise error' do
        expect { channel_info }.to raise_error
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
washbullet-0.4.0 spec/washbullet/api/subscriptions_spec.rb