@Test public void givenServerErrorReturnsTrue() throws Exception { createResponse(HttpStatus.INTERNAL_SERVER_ERROR); assertTrue(errorHandler.hasError(httpResponse)); }
@Override public boolean hasError(ClientHttpResponse clientHttpResponse) throws IOException { final HttpStatus.Series series = clientHttpResponse.getStatusCode().series(); return HttpStatus.Series.CLIENT_ERROR == series || HttpStatus.Series.SERVER_ERROR == series; }
SivaValidationServiceErrorHandler implements ResponseErrorHandler { @Override public boolean hasError(ClientHttpResponse clientHttpResponse) throws IOException { final HttpStatus.Series series = clientHttpResponse.getStatusCode().series(); return HttpStatus.Series.CLIENT_ERROR == series || HttpStatus.Series.SERVER_ERROR == series; } }
SivaValidationServiceErrorHandler implements ResponseErrorHandler { @Override public boolean hasError(ClientHttpResponse clientHttpResponse) throws IOException { final HttpStatus.Series series = clientHttpResponse.getStatusCode().series(); return HttpStatus.Series.CLIENT_ERROR == series || HttpStatus.Series.SERVER_ERROR == series; }  }
SivaValidationServiceErrorHandler implements ResponseErrorHandler { @Override public boolean hasError(ClientHttpResponse clientHttpResponse) throws IOException { final HttpStatus.Series series = clientHttpResponse.getStatusCode().series(); return HttpStatus.Series.CLIENT_ERROR == series || HttpStatus.Series.SERVER_ERROR == series; }  @Override boolean hasError(ClientHttpResponse clientHttpResponse); @Override void handleError(ClientHttpResponse clientHttpResponse); }
SivaValidationServiceErrorHandler implements ResponseErrorHandler { @Override public boolean hasError(ClientHttpResponse clientHttpResponse) throws IOException { final HttpStatus.Series series = clientHttpResponse.getStatusCode().series(); return HttpStatus.Series.CLIENT_ERROR == series || HttpStatus.Series.SERVER_ERROR == series; }  @Override boolean hasError(ClientHttpResponse clientHttpResponse); @Override void handleError(ClientHttpResponse clientHttpResponse);  }