Sha256: a3ff85a186618626e87939efa6385187605a7d3404a055a63f499e5e94af5923
Contents?: true
Size: 323 Bytes
Versions: 3
Compression:
Stored size: 323 Bytes
Contents
require 'spec_helper' module ErrorsSpec class MockModel include Modis::Model attribute :name, :string end end describe Modis::Errors do let(:model) { ErrorsSpec::MockModel.new } it 'adds errors' do model.errors.add(:name, 'is not valid') model.errors[:name].should eq ['is not valid'] end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
modis-1.1.0 | spec/errors_spec.rb |
modis-1.0.0 | spec/errors_spec.rb |
modis-0.0.1 | spec/errors_spec.rb |