Sha256: 1f8d0a2e166ae7a62ad05b04782e96c1ea31c36f9fb57aee0d09b2f221220da9
Contents?: true
Size: 638 Bytes
Versions: 19
Compression:
Stored size: 638 Bytes
Contents
require 'rails_helper' describe LHS::Item do before do class Record < LHS::Record endpoint '{+datastore}/v2/{campaign_id}/feedbacks' endpoint '{+datastore}/v2/feedbacks' end end let(:data) do LHS::Data.new({ addresses: [{ business: { identities: [{ name: 'Löwenzorn' }] } }] }, nil, Record) end context 'item getter' do it 'returns a collection if you access an array' do expect(data.addresses).to be_kind_of(LHS::Data) expect(data.addresses._proxy).to be_kind_of(LHS::Collection) expect(data.addresses.first.business.identities.first.name).to eq 'Löwenzorn' end end end
Version data entries
19 entries across 19 versions & 1 rubygems