Custom write handlers should merge w/ default write handlers

Implemented w/ test (+ support for testing JSON writing w/ custom write
handlers)