Sha256: 5f242beef71050df3eb597e739de7cfb39f42df34f3653ab62fd3be0eed8ec3f

Contents?: true

Size: 505 Bytes

Versions: 1

Compression:

Stored size: 505 Bytes

Contents

# encoding: utf-8

shared_examples_for 'a unary relation method' do
  let(:gateway) { double('New Gateway') }

  before do
    allow(described_class).to receive(:new).and_return(gateway)
  end

  it { should equal(gateway) }

  it 'tests the response is a relation' do
    expect(response).to receive(:kind_of?).with(Relation)
    subject
  end

  it 'initializes the new gateway with the adapter and response' do
    expect(described_class).to receive(:new).with(adapter, response)
    subject
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
axiom-do-adapter-0.2.0 spec/shared/unary_relation_method_behaviour.rb