Sha256: da66705de252df2a4589ff05fc8575fbbe3abe8722d8c93007fa9e1f545eb425
Contents?: true
Size: 766 Bytes
Versions: 2
Compression:
Stored size: 766 Bytes
Contents
# -*- coding: utf-8 -*- require 'spec_helper' describe DataMapper::Validate::ValidationErrors do before :all do @model = DataMapper::Validate::ValidationErrors.new(Object.new) end describe "initially" do it "is empty" do @model.should be_empty end end # Not sure if this is worth having at all, # just keeping old spec suite bits in place # if they make no harm — MK describe "after enquiry" do before :all do @model.on(:property) end it "is still empty" do @model.should be_empty end end describe "after errors being added" do before :all do @model.add(:property, "can't be valid, no way") end it "is no longer empty" do @model.should_not be_empty end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
dm-validations-0.10.1 | spec/unit/validation_errors/emptiness_spec.rb |
dm-validations-0.10.0 | spec/unit/validation_errors/emptiness_spec.rb |