diff --git a/data/beaconrestapi/src/test/java/tech/pegasys/teku/beaconrestapi/handlers/v1/beacon/PostStateValidatorBalancesTest.java b/data/beaconrestapi/src/test/java/tech/pegasys/teku/beaconrestapi/handlers/v1/beacon/PostStateValidatorBalancesTest.java index 0dba514042e..18739d396f7 100644 --- a/data/beaconrestapi/src/test/java/tech/pegasys/teku/beaconrestapi/handlers/v1/beacon/PostStateValidatorBalancesTest.java +++ b/data/beaconrestapi/src/test/java/tech/pegasys/teku/beaconrestapi/handlers/v1/beacon/PostStateValidatorBalancesTest.java @@ -57,13 +57,13 @@ public void shouldGetSpecifiedValidatorBalancesFromState() throws Exception { .build(); request.setRequestBody(List.of("1", "2")); - final Optional>> stateValidatorBalancesData = + final Optional>> expectedData = chainDataProvider.getStateValidatorBalances("head", List.of("1", "2")).get(); handler.handleRequest(request); assertThat(request.getResponseCode()).isEqualTo(SC_OK); - assertThat(request.getResponseBody()).isEqualTo(stateValidatorBalancesData.orElseThrow()); + assertThat(request.getResponseBody()).isEqualTo(expectedData.orElseThrow()); } @Test @@ -74,13 +74,13 @@ public void shouldGetAllValidatorBalancesFromState() throws Exception { .pathParameter("state_id", "head") .build(); - final Optional>> stateValidatorBalancesData = + final Optional>> expectedData = chainDataProvider.getStateValidatorBalances("head", List.of()).get(); handler.handleRequest(request); assertThat(request.getResponseCode()).isEqualTo(SC_OK); - assertThat(request.getResponseBody()).isEqualTo(stateValidatorBalancesData.orElseThrow()); + assertThat(request.getResponseBody()).isEqualTo(expectedData.orElseThrow()); } @Test