Sha256: b9c6f41f3e89468e54dbf526dc9ef63284dd1af44d194271bcb4ef44f414d2d2
Contents?: true
Size: 515 Bytes
Versions: 1
Compression:
Stored size: 515 Bytes
Contents
require 'spec_helper' describe 'Veritas::Tuple#[]' do subject { object[attribute] } let(:klass) { Tuple } let(:header) { Relation::Header.new([ [ :id, Integer ] ]) } let(:object) { klass.new(header, [ 1 ]) } context 'with a known attribute' do let(:attribute) { header[:id] } it { should == 1 } end context 'with an unknown attribute' do let(:attribute) { Attribute::Integer.new(:other_id) } it { should be_nil } end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
veritas-0.0.2 | spec/unit/veritas/tuple/element_reference_spec.rb |