spec/unit/virtus/attribute/integer_spec.rb in virtus-0.0.3 vs spec/unit/virtus/attribute/integer_spec.rb in virtus-0.0.4

- old
+ new

@@ -6,11 +6,10 @@ let(:attribute_value) { 28 } let(:attribute_value_other) { "28" } end describe '#typecast' do - let(:model) { Class.new { include Virtus } } - let(:attribute) { model.attribute(:age, Virtus::Attribute::Integer) } + let(:attribute) { Virtus::Attribute::Integer.new(:age) } subject { attribute.typecast(value) } context "with an integer" do let(:value) { 24 }