use of org.forgerock.util.promise.NeverThrowsException in project OpenAM by OpenRock.
the class RestRouterIT method shouldNotBePossibleToReachInternalResourceViaChf.
@Test
public void shouldNotBePossibleToReachInternalResourceViaChf() throws Exception {
// Given
Context context = mockContext();
Request request = newRequest("GET", "/json/internal");
// When
Promise<Response, NeverThrowsException> promise = handler.handle(context, request);
// Then
Response response = promise.get();
assertThat(response.getStatus()).isEqualTo(Status.NOT_FOUND);
verifyZeroInteractions(internalResource);
}
Aggregations