@Test
    public void testNestedRequiredField()
    {
        Schema<WrapperPojo> schema = WrapperPojo.SCHEMA;
        WrapperPojo message = new WrapperPojo();
        message.requiresName = new RequiresName();
        message.requiresName.description = "some description";

        byte[] data = XmlIOUtil.toByteArray(message, schema);

        WrapperPojo parsed = new WrapperPojo();

        try
        {
            XmlIOUtil.mergeFrom(data, parsed, schema);
        }
        catch (UninitializedMessageException e)
        {
            // expected
            return;
        }

        assertTrue(false);
    }
Testing for xml ser/deser against messages.

@author David Yu
@created May 24, 2010
protostuff-xml/src/test/java/io/protostuff/XmlCoreSerDeserTest.java