diff --git a/spring-boot-modules/spring-boot-testing-2/src/test/java/com/baeldung/keycloaktestcontainers/IntegrationTest.java b/spring-boot-modules/spring-boot-testing-2/src/test/java/com/baeldung/keycloaktestcontainers/KeycloakTestContainers.java similarity index 95% rename from spring-boot-modules/spring-boot-testing-2/src/test/java/com/baeldung/keycloaktestcontainers/IntegrationTest.java rename to spring-boot-modules/spring-boot-testing-2/src/test/java/com/baeldung/keycloaktestcontainers/KeycloakTestContainers.java index 902c27b16e..44e24c98d1 100644 --- a/spring-boot-modules/spring-boot-testing-2/src/test/java/com/baeldung/keycloaktestcontainers/IntegrationTest.java +++ b/spring-boot-modules/spring-boot-testing-2/src/test/java/com/baeldung/keycloaktestcontainers/KeycloakTestContainers.java @@ -26,11 +26,11 @@ import org.springframework.web.reactive.function.client.WebClient; import dasniko.testcontainers.keycloak.KeycloakContainer; import io.restassured.RestAssured; -@ContextConfiguration(initializers = { IntegrationTest.Initializer.class }) +@ContextConfiguration(initializers = { KeycloakTestContainers.Initializer.class }) @SpringBootTest(webEnvironment = WebEnvironment.RANDOM_PORT) -public abstract class IntegrationTest { +public abstract class KeycloakTestContainers { - private static final Logger LOGGER = LoggerFactory.getLogger(IntegrationTest.class.getName()); + private static final Logger LOGGER = LoggerFactory.getLogger(KeycloakTestContainers.class.getName()); @LocalServerPort private int port; diff --git a/spring-boot-modules/spring-boot-testing-2/src/test/java/com/baeldung/keycloaktestcontainers/UserControllerIntegrationTest.java b/spring-boot-modules/spring-boot-testing-2/src/test/java/com/baeldung/keycloaktestcontainers/UserControllerManualTest.java similarity index 77% rename from spring-boot-modules/spring-boot-testing-2/src/test/java/com/baeldung/keycloaktestcontainers/UserControllerIntegrationTest.java rename to spring-boot-modules/spring-boot-testing-2/src/test/java/com/baeldung/keycloaktestcontainers/UserControllerManualTest.java index 4015612860..817c8ae130 100644 --- a/spring-boot-modules/spring-boot-testing-2/src/test/java/com/baeldung/keycloaktestcontainers/UserControllerIntegrationTest.java +++ b/spring-boot-modules/spring-boot-testing-2/src/test/java/com/baeldung/keycloaktestcontainers/UserControllerManualTest.java @@ -5,7 +5,11 @@ import static org.hamcrest.Matchers.equalTo; import org.junit.jupiter.api.Test; -class UserControllerIntegrationTest extends IntegrationTest { +/** + * Requires Docker running on the machine to run without errors + * Therefore, skipped from pipeline + */ +class UserControllerManualTest extends KeycloakTestContainers { @Test void givenAuthenticatedUser_whenGetMe_shouldReturnMyInfo() {