tester.startResource(new RSSProducerResource());
String responseTxt = tester.getLastResponse().getDocument();
//write the RSS feed used in the test into a ByteArrayOutputStream
ByteArrayOutputStream outputStream = new ByteArrayOutputStream();
Writer writer = new OutputStreamWriter(outputStream);
SyndFeedOutput output = new SyndFeedOutput();
output.output(RSSProducerResource.getFeed(), writer);
//the response and the written RSS must be equal
Assert.assertEquals(responseTxt, outputStream.toString());
}