@Test
public void testReadOperation() throws Exception {

    Object answer = endpoint.doReadAction("foo-route", ReadAction.INFO);
    Assert.assertEquals(RouteEndpointInfo.class, answer.getClass());
    Assert.assertEquals("foo-route", RouteEndpointInfo.class.cast(answer).getId());
    answer = endpoint.doReadAction("foo-route", ReadAction.DETAIL);
    Assert.assertEquals(RouteDetailsEndpointInfo.class, answer.getClass());
}