This is an automated email from the ASF dual-hosted git repository. ilgrosso pushed a commit to branch 4_0_X in repository https://gitbox.apache.org/repos/asf/syncope.git
commit c3a1a500c0b0165009e354518e63c9969b2d4302 Author: Francesco Chicchiriccò <[email protected]> AuthorDate: Fri Nov 14 09:58:38 2025 +0100 Upgrading TestContainers --- core/persistence-jpa/pom.xml | 6 +++--- .../apache/syncope/core/persistence/jpa/AbstractTest.java | 12 ++++++------ ext/openfga/client-openfga/pom.xml | 2 +- pom.xml | 14 +++++++------- 4 files changed, 17 insertions(+), 17 deletions(-) diff --git a/core/persistence-jpa/pom.xml b/core/persistence-jpa/pom.xml index ceb4ff14b6..62da0fa90f 100644 --- a/core/persistence-jpa/pom.xml +++ b/core/persistence-jpa/pom.xml @@ -107,17 +107,17 @@ under the License. </dependency> <dependency> <groupId>org.testcontainers</groupId> - <artifactId>mysql</artifactId> + <artifactId>testcontainers-mysql</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>org.testcontainers</groupId> - <artifactId>mariadb</artifactId> + <artifactId>testcontainers-mariadb</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>org.testcontainers</groupId> - <artifactId>oracle-free</artifactId> + <artifactId>testcontainers-oracle-free</artifactId> <scope>test</scope> </dependency> </dependencies> diff --git a/core/persistence-jpa/src/test/java/org/apache/syncope/core/persistence/jpa/AbstractTest.java b/core/persistence-jpa/src/test/java/org/apache/syncope/core/persistence/jpa/AbstractTest.java index 73428bb16d..5f26de86bc 100644 --- a/core/persistence-jpa/src/test/java/org/apache/syncope/core/persistence/jpa/AbstractTest.java +++ b/core/persistence-jpa/src/test/java/org/apache/syncope/core/persistence/jpa/AbstractTest.java @@ -36,8 +36,8 @@ import org.springframework.test.context.DynamicPropertyRegistry; import org.springframework.test.context.DynamicPropertySource; import org.springframework.test.context.TestPropertySource; import org.springframework.test.context.junit.jupiter.SpringJUnitConfig; -import org.testcontainers.containers.MariaDBContainer; -import org.testcontainers.containers.MySQLContainer; +import org.testcontainers.mariadb.MariaDBContainer; +import org.testcontainers.mysql.MySQLContainer; import org.testcontainers.oracle.OracleContainer; @SpringJUnitConfig(classes = { MasterDomain.class, PersistenceTestContext.class }) @@ -126,7 +126,7 @@ public abstract class AbstractTest { INDEXES = "classpath:META-INF/mysql/indexes.xml"; VIEWS = "classpath:META-INF/mysql/views.xml"; - MySQLContainer<?> masterDomain = new MySQLContainer<>("mysql:" + dockerMySQLVersion). + MySQLContainer masterDomain = new MySQLContainer("mysql:" + dockerMySQLVersion). withTmpFs(Map.of("/var/lib/mysql", "rw")). withDatabaseName("syncope").withPassword("syncope").withUsername("syncope"). withUrlParam("characterEncoding", "UTF-8"). @@ -134,7 +134,7 @@ public abstract class AbstractTest { masterDomain.start(); JDBC_URL_SUPPLIER = masterDomain::getJdbcUrl; - MySQLContainer<?> twoDomain = new MySQLContainer<>("mysql:" + dockerMySQLVersion). + MySQLContainer twoDomain = new MySQLContainer("mysql:" + dockerMySQLVersion). withTmpFs(Map.of("/var/lib/mysql", "rw")). withDatabaseName("syncope").withPassword("syncope").withUsername("syncope"). withUrlParam("characterEncoding", "UTF-8"). @@ -149,7 +149,7 @@ public abstract class AbstractTest { INDEXES = "classpath:META-INF/mariadb/indexes.xml"; VIEWS = "classpath:META-INF/mariadb/views.xml"; - MariaDBContainer<?> masterDomain = new MariaDBContainer<>("mariadb:" + dockerMariaDBVersion). + MariaDBContainer masterDomain = new MariaDBContainer("mariadb:" + dockerMariaDBVersion). withTmpFs(Map.of("/var/lib/mysql", "rw")). withDatabaseName("syncope").withPassword("syncope").withUsername("syncope"). withUrlParam("characterEncoding", "UTF-8"). @@ -157,7 +157,7 @@ public abstract class AbstractTest { masterDomain.start(); JDBC_URL_SUPPLIER = masterDomain::getJdbcUrl; - MariaDBContainer<?> twoDomain = new MariaDBContainer<>("mariadb:" + dockerMariaDBVersion). + MariaDBContainer twoDomain = new MariaDBContainer("mariadb:" + dockerMariaDBVersion). withTmpFs(Map.of("/var/lib/mysql", "rw")). withDatabaseName("syncope").withPassword("syncope").withUsername("syncope"). withUrlParam("characterEncoding", "UTF-8"). diff --git a/ext/openfga/client-openfga/pom.xml b/ext/openfga/client-openfga/pom.xml index 5361f2572b..a443e1107e 100644 --- a/ext/openfga/client-openfga/pom.xml +++ b/ext/openfga/client-openfga/pom.xml @@ -62,7 +62,7 @@ under the License. </dependency> <dependency> <groupId>org.testcontainers</groupId> - <artifactId>openfga</artifactId> + <artifactId>testcontainers-openfga</artifactId> <scope>test</scope> </dependency> </dependencies> diff --git a/pom.xml b/pom.xml index 46884e5dbe..105dacc371 100644 --- a/pom.xml +++ b/pom.xml @@ -494,7 +494,7 @@ under the License. <byte-buddy.jdk25.version>1.17.8</byte-buddy.jdk25.version> <mockito.jdk25.version>5.20.0</mockito.jdk25.version> - <testcontainers.version>1.21.3</testcontainers.version> + <testcontainers.version>2.0.2</testcontainers.version> <zonky.embedded-postgres.version>2.1.1</zonky.embedded-postgres.version> <zonky.embedded-postgres-binaries.version>17.6.0</zonky.embedded-postgres-binaries.version> @@ -1367,37 +1367,37 @@ under the License. </dependency> <dependency> <groupId>org.testcontainers</groupId> - <artifactId>jdbc</artifactId> + <artifactId>testcontainers-jdbc</artifactId> <version>${testcontainers.version}</version> <scope>test</scope> </dependency> <dependency> <groupId>org.testcontainers</groupId> - <artifactId>database-commons</artifactId> + <artifactId>testcontainers-database-commons</artifactId> <version>${testcontainers.version}</version> <scope>test</scope> </dependency> <dependency> <groupId>org.testcontainers</groupId> - <artifactId>mysql</artifactId> + <artifactId>testcontainers-mysql</artifactId> <version>${testcontainers.version}</version> <scope>test</scope> </dependency> <dependency> <groupId>org.testcontainers</groupId> - <artifactId>mariadb</artifactId> + <artifactId>testcontainers-mariadb</artifactId> <version>${testcontainers.version}</version> <scope>test</scope> </dependency> <dependency> <groupId>org.testcontainers</groupId> - <artifactId>oracle-free</artifactId> + <artifactId>testcontainers-oracle-free</artifactId> <version>${testcontainers.version}</version> <scope>test</scope> </dependency> <dependency> <groupId>org.testcontainers</groupId> - <artifactId>openfga</artifactId> + <artifactId>testcontainers-openfga</artifactId> <version>${testcontainers.version}</version> <scope>test</scope> </dependency>
