mongoid/mongoid — pull request #3230 by rodrigosaito (2013-08-22 01:52:25+00:00)
Title: Array/Hash fields should fail somehow when assigned the wrong type.

[ fix #2442 ] [ fix #2471]

Creating a new pull request, because the old one was asking to pull to mongoid:3.0.0-stable branch instead of the master branch, and after rebasing the branch against master the pull request was totally messy.

I think it's not possible to change the branch in the PR so I created this new one

@arthurnn