public void testAttributeAndElement() throws IOException
{
XmlMapper mapper = new XmlMapper();
mapper.setAnnotationIntrospector(new JaxbAnnotationIntrospector(TypeFactory.defaultInstance()));
String xml = mapper.writeValueAsString(new Problem("x", "Stuff"));
assertEquals("<problem id=\"x\"><description>Stuff</description></problem>", xml);
}
}