OK, I think this is the last one for a while, but after the last set of pulls I realized that AutoValidations is full of stateless methods and doesn't need to add them all to Model.
The last commit in this pull request moves the setup of AutoValidation from Property.new to Model#property, I don't have a specific justification for this move, other than the sense that AutoValidation is more a responsibility of Model creating and binding a property than of Property initialization generally. Also, if a Property is created by Property.new but not via Model#property, that property probably shouldn't be auto-validated.
OK, I think this is the last one for a while, but after the last set of pulls I realized that AutoValidations is full of stateless methods and doesn't need to add them all to Model.
The last commit in this pull request moves the setup of AutoValidation from Property.new to Model#property, I don't have a specific justification for this move, other than the sense that AutoValidation is more a responsibility of Model creating and binding a property than of Property initialization generally. Also, if a Property is created by
Property.new
but not viaModel#property
, that property probably shouldn't be auto-validated.