Sha256: f27369b08ee15bc468e99356ddc43cdbedaec28196bbcc1df26d9d4bb457fd0e

Contents?: true

Size: 425 Bytes

Versions: 3

Compression:

Stored size: 425 Bytes

Contents

require 'spec_helper'

describe Me do
  let(:session) { Fabricate :oauth_session }

  it 'performs a get on the /me api path' do
    expect(session).to receive(:get).with('/me').and_return({})
    Me.run!(session: session)
  end

  it 'returns the me entry from the response' do
    allow(session).to receive(:get).with('/me').and_return 'me' => 'some_info'
    expect(Me.run!(session: session)).to eq('some_info')
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
roqua-core-api-0.0.12 spec/lib/roqua/core_api/me_spec.rb
roqua-core-api-0.0.11 spec/lib/roqua/core_api/me_spec.rb
roqua-core-api-0.0.10 spec/lib/roqua/core_api/me_spec.rb