technoweenie/serialized_attributes — comment on commit c5d4f5961cf031952515f38e36128f15730c9fe3
File:  line 0
By reinh:

encode(false) # => nil

is a critical bug.

assert_equal 0, type.encode(false)
assert_equal 1, type.encode(true)

seems like a pretty good pair of tests to include for a boolean serializer.

Also, `nil` (SQL `NULL)` is a very strange thing for a boolean serializer to return in any event as `NULL` is neither true nor false.