@Test
public void testSuccessAndFailure() throws Exception {

    URL url = getUniqueURL(PATH_TO_RESOURCE);
    assertNotNull(testClient.get(url));
    // The server stops responding
    Mockito.doNothing().when(server.getHandler()).handle(any(), any(), any(), any());
    assertNotNull(testClient.get(url));
    verify(server.getHandler(), times(1)).handle(any(), any(), any(), any());
}