Sha256: 2c29187faeff93c34eaa8200e26bde364b180f5dc83657980cd87777f24b320c
Contents?: true
Size: 510 Bytes
Versions: 3
Compression:
Stored size: 510 Bytes
Contents
require 'spec_helper' describe Yema::Rule::Required, '#errors' do subject { rule.errors(resource) } let(:rule) { described_class.new(attribute, options) } let(:resource) { stub('resource', attribute => value) } let(:attribute) { :foo } let(:options) { {} } [ nil, "", {}, [], ].each do |value| it_behaves_like "invalid resource", value end it_behaves_like "valid resource", "bar" end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
yema-0.0.3 | spec/integration/rule/required_spec.rb |
yema-0.0.2 | spec/integration/rule/required_spec.rb |
yema-0.0.1 | spec/integration/rule/required_spec.rb |