Sha256: 2f8054ea07bbdbc3d70ef310d36586846499c9f794675c40964df5f3f126846a

Contents?: true

Size: 476 Bytes

Versions: 8

Compression:

Stored size: 476 Bytes

Contents

require 'spec_helper'

describe WialonApi::Client do
  let(:sid) { 'sid' }

  describe '#authorized?' do
    context 'with an unauthorized client' do
      let(:client) { WialonApi::Client.new }

      it 'returns false' do
        expect(client).not_to be_authorized
      end
    end

    context 'with an authorized client' do
      let(:client) { WialonApi::Client.new(sid) }

      it 'returns true' do
        expect(client).to be_authorized
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
wialon_api-0.0.8 spec/wialon_api/client_spec.rb
wialon_api-0.0.7 spec/wialon_api/client_spec.rb
wialon_api-0.0.6 spec/wialon_api/client_spec.rb
wialon_api-0.0.5 spec/wialon_api/client_spec.rb
wialon_api-0.0.4 spec/wialon_api/client_spec.rb
wialon_api-0.0.3 spec/wialon_api/client_spec.rb
wialon_api-0.0.2 spec/wialon_api/client_spec.rb
wialon_api-0.0.1 spec/wialon_api/client_spec.rb