spec/public/json_model_spec.rb in pp-adaptive-0.0.6 vs spec/public/json_model_spec.rb in pp-adaptive-1.0.0
- old
+ new
@@ -2,13 +2,13 @@
require "virtus"
describe AdaptivePayments::JsonModel do
let(:model) do
Class.new(AdaptivePayments::JsonModel) do
- attribute :an_example, Virtus::Attribute::String, :param => "anExample"
- attribute :simple, Virtus::Attribute::String
- attribute :numeric, Virtus::Attribute::Decimal
- attribute :optional, Virtus::Attribute::String, :default => "test"
+ attribute :an_example, String, :param => "anExample"
+ attribute :simple, String
+ attribute :numeric, BigDecimal
+ attribute :optional, String, :default => "test"
end
end
describe "coercion" do
let(:object) { model.new(:an_example => "string", :numeric => 20) }