spec/helpers/models.rb in motion-prime-0.3.1 vs spec/helpers/models.rb in motion-prime-0.3.2
- old
+ new
@@ -1,41 +1,48 @@
class User < MotionPrime::BaseModel
attributes :id, :name, :age, :created_at
end
class Plane < MotionPrime::BaseModel
- attributes :name, :age
+ attributes :id, :name, :age
end
class Listing < MotionPrime::BaseModel
+ attribute :id
attribute :name
end
class Todo < MotionPrime::BaseModel
+ attribute :id
attribute :title
bag :items
end
class TodoItem < MotionPrime::BaseModel
+ attribute :id
attribute :completed
attribute :text
end
class Page < MotionPrime::BaseModel
+ attribute :id
attribute :text
attribute :index
end
class Animal < MotionPrime::BaseModel
+ attribute :id
attribute :name
end
class Autobot < MotionPrime::BaseModel
+ attribute :id
attribute :name
end
module CustomModule; end
class CustomModule::Car < MotionPrime::BaseModel
+ attribute :id
attribute :name
attribute :created_at
end
Car = CustomModule::Car
\ No newline at end of file