public static <T> T toObject(final String text, final Class<T> clazz) {
        try {
            return DEFAULT_MAPPER.readValue(text, clazz);
        } catch (JsonProcessingException e) {
            throw new MocoException(e);
        }
    }
@Test
    public void should_convert_xml_to_object() {
        final String xml = "<request><parameter><id>1</id></parameter></request>";
        final TestRequest request = Xmls.toObject(xml, TestRequest.class);
        assertThat(request.getParameters().getId(), is("1"));
    }