Search in sources :

Example 1 with RequestTimeoutException

use of com.yahoo.vespa.config.server.http.RequestTimeoutException in project vespa by vespa-engine.

the class HttpProxyTest method testFetchException.

@Test(expected = RequestTimeoutException.class)
public void testFetchException() {
    when(fetcher.get(any(), any())).thenThrow(new RequestTimeoutException("timed out"));
    HttpResponse actualResponse = proxy.get(applicationMock, hostname, "container-clustercontroller", "clustercontroller-status/v1/clusterName");
}
Also used : RequestTimeoutException(com.yahoo.vespa.config.server.http.RequestTimeoutException) HttpResponse(com.yahoo.container.jdisc.HttpResponse) Test(org.junit.Test)

Aggregations

HttpResponse (com.yahoo.container.jdisc.HttpResponse)1 RequestTimeoutException (com.yahoo.vespa.config.server.http.RequestTimeoutException)1 Test (org.junit.Test)1