Sha256: 0f8fe4463b53417c445778514e9424b65901456b0ab3527add6f4b2610811bc9
Contents?: true
Size: 751 Bytes
Versions: 14
Compression:
Stored size: 751 Bytes
Contents
require 'spec_helper' describe 'DataMapper::Validations::GenericValidator' do describe "when types and fields are equal" do it "returns true" do DataMapper::Validations::PresenceValidator.new(:name). should == DataMapper::Validations::PresenceValidator.new(:name) end end describe "when types differ" do it "returns false" do DataMapper::Validations::PresenceValidator.new(:name). should_not == DataMapper::Validations::UniquenessValidator.new(:name) end end describe "when property names differ" do it "returns false" do DataMapper::Validations::PresenceValidator.new(:first_name). should_not == DataMapper::Validations::PresenceValidator.new(:last_name) end end end
Version data entries
14 entries across 14 versions & 2 rubygems