spec/unit/datacite/mapping/identifier_spec.rb in datacite-mapping-0.1.17.1 vs spec/unit/datacite/mapping/identifier_spec.rb in datacite-mapping-0.1.17.2

- old
+ new

@@ -9,9 +9,13 @@ value = '10.14749/1407399495' id = Identifier.new(value: value) expect(id.value).to eq(value) end + it 'requires a non-nil value' do + expect { Identifier.new(value: nil) }.to raise_error(ArgumentError) + end + it 'sets the type' do id = Identifier.new(value: '10.14749/1407399495') expect(id.identifier_type).to eq('DOI') end