diff --git a/spring-security-cache-control/src/test/java/com/baeldung/cachecontrol/ResourceEndpointLiveTest.java b/spring-security-cache-control/src/test/java/com/baeldung/cachecontrol/ResourceEndpointTest.java similarity index 95% rename from spring-security-cache-control/src/test/java/com/baeldung/cachecontrol/ResourceEndpointLiveTest.java rename to spring-security-cache-control/src/test/java/com/baeldung/cachecontrol/ResourceEndpointTest.java index 94b6052ba4..6d532f98fc 100644 --- a/spring-security-cache-control/src/test/java/com/baeldung/cachecontrol/ResourceEndpointLiveTest.java +++ b/spring-security-cache-control/src/test/java/com/baeldung/cachecontrol/ResourceEndpointTest.java @@ -11,7 +11,7 @@ import static com.jayway.restassured.RestAssured.given; @RunWith(SpringRunner.class) @SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT, classes = AppRunner.class) -public class ResourceEndpointLiveTest { +public class ResourceEndpointTest { @LocalServerPort private int serverPort; @@ -66,7 +66,7 @@ public class ResourceEndpointLiveTest { } private String getBaseUrl() { - return "http://localhost:" + serverPort; + return String.format("http://localhost:%d", serverPort); } } \ No newline at end of file