spec/inheritance_spec.rb in soulless-0.5.0.rc5 vs spec/inheritance_spec.rb in soulless-0.5.0

- old
+ new

@@ -3,49 +3,49 @@ describe Soulless::Inheritance do describe DummyModelInheritance do before(:each) do @dummy_inheritance = DummyModelInheritance.new end - + it 'should inherit the name attribute' do @dummy_inheritance.attributes.keys.should include(:name) end - + it 'should inherit the default value for the name attribute' do @dummy_inheritance.attributes[:name].should == 'Anthony' end - + it 'should not inhert the email attribute when added as exclude option' do @dummy_inheritance.attributes.keys.should_not include(:email) end - + it 'should validate presence of name' do @dummy_inheritance.name = nil @dummy_inheritance.valid? @dummy_inheritance.errors[:name].should include("can't be blank") end - + it 'should not validate email' do @dummy_inheritance.class.validators.each do |validator| validator.attributes.should_not include(:email) end end end - + describe DummySoullessInheritance do before(:each) do @dummy_inheritance = DummySoullessInheritance.new end - + it 'should inherit the name attribute' do @dummy_inheritance.attributes.keys.should include(:name) end - + it 'should inherit the default value for the name attribute' do @dummy_inheritance.attributes[:name].should == 'Anthony' end - + it 'should not inhert the email attribute when added as exclude option' do @dummy_inheritance.attributes.keys.should_not include(:email) end end -end \ No newline at end of file +end