When using embed: :ids ; embed_in_root: true, and serializing multiple objects,
only the associated objects of the last object in the collection will actually
show up in the serialized data.

For example, if you serialize a collection of two posts, each containing one or
more comments, only the comments of the last post show up. The reason is a
Hash#merge wich overwrites the array rather than appending to it.

This commit fixes this by merging the collection arrays, rather than the top-level
hashes.
Fixes a bug in the HasOne association where serializing twice in a row causes
an exception.
Serializers now inherit attributes and associations.
Merge pull request #451 from plexus/embed_in_root_merge

embed_in_root only returns the associated objects of a single instance
Split basic object and model array serialization tests
Move serialization tests to serialization_test.rb
Stub out comments writer when needed
Merge pull request #468 from stas/attrs_and_assoc_inheritance

Serializers now inherit attributes and associations.
Remove explicit reference to self
Test association inheritance in serializers
Serializers now inherit root
Merge pull request #452 from plexus/has_one_each_serializer_fix

Using a HasOne association twice raises an exception (Undefined method `map')
Avoid unneeded logic
Clean up HasOne array wrapping logic

Introduce private _wrap_in_array option for now.
Rename method to serializable_object
Merge with api/master
Test using a structure that returns a consistent value on Rails 4.0 & 4.1
Remove useless test that behaves differently in different Rails versions
Move edge out from allow_failures on Travis
Add dependencies needed to run Rubinius tests