{
m_marshaller.serialize(m_soapFault, m_writer);
XMLUtil.parse(new StringReader(m_writer.toString()), m_xsdMap); // validate to XSD
StringReader reader = new StringReader(m_writer.toString());
SOAPFault fault = (SOAPFault)m_unmarshaller.deserialize(reader);
assertEquals("http://schemas.xmlsoap.org/soap/envelope/", fault.getURI());
assertEquals("Server.nexj.core.runtime.ValidationException", fault.getCode());
assertEquals("err.validation.requiredAttributes(\"Contact\")", fault.getMessage());
assertEquals("err.validation.requiredAttributes",
((ValidationException)fault.getException()).getErrorCode());
}