diff --git a/api/common/src/test/kotlin/uk/co/baconi/oauth/api/common/token/RefreshTokenRepositoryIntegrationTest.kt b/api/common/src/test/kotlin/uk/co/baconi/oauth/api/common/token/RefreshTokenRepositoryIntegrationTest.kt index 75a2f2b4..501135b1 100644 --- a/api/common/src/test/kotlin/uk/co/baconi/oauth/api/common/token/RefreshTokenRepositoryIntegrationTest.kt +++ b/api/common/src/test/kotlin/uk/co/baconi/oauth/api/common/token/RefreshTokenRepositoryIntegrationTest.kt @@ -13,7 +13,9 @@ import org.h2.jdbc.JdbcSQLIntegrityConstraintViolationException import org.jetbrains.exposed.exceptions.ExposedSQLException import org.jetbrains.exposed.sql.Database import org.jetbrains.exposed.sql.SchemaUtils +import org.jetbrains.exposed.sql.deleteAll import org.jetbrains.exposed.sql.transactions.transaction +import org.junit.jupiter.api.AfterEach import org.junit.jupiter.api.Nested import org.junit.jupiter.api.Test import uk.co.baconi.oauth.api.common.authentication.AuthenticatedUsername @@ -44,6 +46,13 @@ class RefreshTokenRepositoryIntegrationTest { private val underTest = RefreshTokenRepository(database) + @AfterEach + fun cleanDatabase() { + transaction(database) { + RefreshTokenTable.deleteAll() + } + } + @Nested inner class Insert { diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index e00aea35..bc0a3450 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -25,7 +25,7 @@ mockk = "1.14.6" ## # JVM Test Versions ## -junit = "5.13.2" +junit = "6.0.1" selenide = "7.12.1" restAssured = "5.5.6" commonsLang3 = "3.18.0"