Sha256: ff7ae4a457ebbc11eecd38b8fbf75656d418b6625a33d797d6dffde66c3a64f3
Contents?: true
Size: 850 Bytes
Versions: 11
Compression:
Stored size: 850 Bytes
Contents
require 'spec_helper' require 'dm-core/support/subject_set' require 'unit/data_mapper/subject_set/shared/named_spec' describe 'DataMapper::SubjectSet#named?' do before :all do class ::Person attr_reader :name def initialize(name) @name = name end end end subject { set.named?(name) } let(:entry) { Person.new(name) } let(:name ) { 'Alice' } context 'when no entry with the given name is present' do let(:set) { DataMapper::SubjectSet.new([]) } it_should_behave_like 'DataMapper::SubjectSet#named? when no entry with the given name is present' end context 'when an entry with the given name is present' do let(:set) { DataMapper::SubjectSet.new([ entry ]) } it_should_behave_like 'DataMapper::SubjectSet#named? when an entry with the given name is present' end end
Version data entries
11 entries across 11 versions & 3 rubygems