String xml = "<collection xmlns:foo=\"http://foo.com\">"
+ "<foo:foo test=\"hello\"/></collection>";
ClientRequest request = new ClientRequest(generateURL("/namespaced/array"));
request.body("application/xml", xml);
ClientResponse<List<NamespacedFoo>> response = request.post(new GenericType<List<NamespacedFoo>>()
{
});
List<NamespacedFoo> list = response.getEntity();
Assert.assertEquals(1, list.size());
Assert.assertEquals(list.get(0).getTest(), "hello");