rails/activemodel/test
John Firebaugh 4860143ee4 ActiveModel support for the :include serialization option
This commit moves support for the :include serialization option for
serializing associated objects out of ActiveRecord in into ActiveModel.
The following methods support the :include option:

  * serializable_hash
  * to_json
  * to_xml

Instances must respond to methods named by the values of the :includes
array (or keys of the :includes hash). If an association method returns
an object that is_a?(Enumerable) (which AR has_many associations do), it
is assumed to be a collection association, and its elements must respond
to :serializable_hash. Otherwise it must respond to :serializable_hash
itself.

While here, fix #858, XmlSerializer should not singularize already
singular association names.
2011-07-17 11:34:07 -07:00
..
cases ActiveModel support for the :include serialization option 2011-07-17 11:34:07 -07:00
models Allow to specify mass-assignment roles as array 2011-06-23 12:56:39 +06:00
validators This is not an executable file 2010-12-16 01:49:28 +05:30
config.rb Make Active Model test suite similar to Active Record 2009-03-20 10:32:24 +00:00