### Question:
Explorer { public LedgerValidationResult validate(String assetId) { return clientService.validateLedger(assetId); } Explorer(ClientService clientService, ClientConfig clientConfig); void initialize(); LedgerValidationResult validate(String assetId); JsonObject listContracts(); JsonObject get(String assetId); JsonArray scan(String assetId, JsonObject condition);  }### Answer:
@Test public void validate_ErrorStatusCodeReturned_ShouldThrowClientException() { when(clientException.getStatusCode()).thenReturn(StatusCode.DATABASE_ERROR); when(clientException.getMessage()).thenReturn("message"); when(clientService.validateLedger(ASSET_ID)).thenThrow(clientException); Throwable thrown = catchThrowable(() -> { explorer.validate(ASSET_ID); }); assertThat(thrown).isInstanceOf(ClientException.class); ClientException clientException = (ClientException) thrown; assertThat(clientException.getStatusCode()).isEqualTo(StatusCode.DATABASE_ERROR); }