Sha256: 56f92cb08cb87666a507e4ab05fc0e1631b36311f47accdb288f796cf216fa15
Contents?: true
Size: 637 Bytes
Versions: 98
Compression:
Stored size: 637 Bytes
Contents
require 'rails_helper' describe LHS::Data do before(:each) do class Record < LHS::Record endpoint 'http://local.ch/records' end end let(:item) do { customer: { address: { first_line: 'Bachstr. 6' } } } end let(:data) do LHS::Data.new( { href: 'http://local.ch/records', items: [item] }, nil, Record ) end it 'possible to navigate the parent' do expect( data.first.customer.address.parent ).to eq data.first.customer expect( data.first.customer.address.parent.parent ).to eq data.first end end
Version data entries
98 entries across 98 versions & 1 rubygems