Skip to content

Commit

Permalink
fix checkstyle
Browse files Browse the repository at this point in the history
Signed-off-by: Seddik Yengui <seddik.yengui_externe@rte-france.com>
  • Loading branch information
Seddik Yengui committed Dec 24, 2024
1 parent 7d34857 commit e8f0b7e
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
import org.springframework.test.context.junit4.SpringRunner;
import org.springframework.test.web.client.ExpectedCount;
import org.springframework.test.web.client.MockRestServiceServer;
import org.springframework.web.client.HttpClientErrorException;
import org.springframework.web.client.ResourceAccessException;

import java.io.IOException;
Expand Down Expand Up @@ -344,9 +343,9 @@ public void testDeleteAll() {
server.expect(ExpectedCount.times(2), requestTo("/networks/" + networkUuid + "/" + Resource.INITIAL_VARIANT_NUM + "/substations"))
.andExpect(method(DELETE))
.andExpect(content().string("[\"wrongId2\"]"))
.andRespond((request -> {
.andRespond(request -> {
throw new ResourceAccessException("ResourceAccessException error");
}));
});
ResourceAccessException httpClientErrorException = assertThrows(ResourceAccessException.class, () -> restNetworkStoreClient.removeSubstations(networkUuid, Resource.INITIAL_VARIANT_NUM, List.of("wrongId2")));
assertEquals("ResourceAccessException error", httpClientErrorException.getMessage());
server.verify();
Expand Down

0 comments on commit e8f0b7e

Please sign in to comment.