Named definition that accepts :class param?
iawgens opened this issue · comments
Any plan to add ability to name the definition that are different than the model it would create, like in Factory Girl.
Something like:
Dupe.define :fancy_recipe, :class => Recipe do |t|
t.name "Fancy Recipe"
end
I think the usage of this is so one can create a factory of a particular pattern easily.
definitely, though instead of ":class => Recipe", it should be something like ":type_of => :recipe", since we often define duped models for which we never create a corresponding ActiveResource model.