public void testBarNullFields() throws Exception
    {
        Bar b = new Bar();
        JsonIOUtil.mergeFrom(JsonIOUtil.DEFAULT_JSON_FACTORY.createJsonParser(
                "{\"someInt\":null" +
                        ",\"someString\":null" +
                        ",\"someBaz\":null" +
                        ",\"someEnum\":null" +
                        ",\"someBytes\":null" +
                        ",\"someBoolean\":null" +
                        ",\"someFloat\":null" +
                        ",\"someDouble\":null" +
                        ",\"someLong\":null}"),
                b, b.cachedSchema(), false);

        assertEquals(0, b.getSomeInt());
        assertNull(b.getSomeString());
        assertNull(b.getSomeBaz());
        assertNull(b.getSomeEnum());
        assertNull(b.getSomeBytes());
        assertFalse(b.getSomeBoolean());
        assertEquals(0f, b.getSomeFloat());
        assertEquals(0d, b.getSomeDouble());
        assertEquals(0l, b.getSomeLong());
    }
Testing for json ser/deser against messages.

@author David Yu
@created Nov 20, 2009
protostuff-json/src/test/java/io/protostuff/JsonCoreSerDeserTest.java