@Test
public void shouldGetZoomRadius() throws Exception {
String xmlToBeSent = TestConstants.XML_HEADER + xstream.toXML(createAZoomRadius());
Response responseFromWs =
HttpClient.doPost(
TestConstants.getMapRenderUrl(),
xmlToBeSent);
String body = responseFromWs.getBody();
Assert.assertEquals("200", responseFromWs.getStatusCode());
Assert.assertEquals("text/xml;charset=UTF-8", responseFromWs.getContentType());
Assert.assertTrue(body.startsWith("<?xml version='1.0' encoding='UTF-8'?>"));
Document xmlParsed = XmlParser.parse(body);
Response responseFromImage =
HttpClient.doGet(
xmlParsed
.getElementsByTagName("url")
.item(0)
.getFirstChild()
.getNodeValue());
Assert.assertEquals("200", responseFromImage.getStatusCode());
}