spec/support/active_model_lint.rb in active-triples-0.7.6 vs spec/support/active_model_lint.rb in active-triples-0.8.0

- old
+ new

@@ -4,11 +4,14 @@ describe '#to_key' do it 'should respond' do expect(subject).to respond_to :to_key end - it 'should return nil when #persisted? is false ' do + ## + # @todo FIXME: this is wrong according to + # http://api.rubyonrails.org/classes/ActiveModel/Conversion.html#method-i-to_key + xit 'should return nil when #persisted? is false ' do def subject.persisted?() false end expect(subject.to_key).to eq nil end end @@ -71,11 +74,11 @@ it 'should return a boolean' do expect(match_boolean(subject.destroyed?)).to be true end end - private - + private + def match_boolean(result) result == true || result == false end end