Skip to content

Commit 3ad5c64

Browse files
committed
Migrate JUnit deps to Gradle's version catalog
1 parent 4a4851f commit 3ad5c64

2 files changed

Lines changed: 10 additions & 4 deletions

File tree

build.gradle.kts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -100,15 +100,15 @@ dependencies {
100100
testImplementation(libs.okhttpMockwebserver)
101101
testImplementation(libs.okhttpMockwebserverJunit5)
102102
testImplementation(libs.okhttpLoggingInterceptor)
103-
testImplementation("org.junit.jupiter:junit-jupiter-api:6.1.0")
104-
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:6.1.0")
105-
testRuntimeOnly("org.junit.platform:junit-platform-launcher:6.1.0")
103+
testImplementation(libs.bundles.junit)
106104
}
107105

108106
val dependencyVersions = listOf<String>(
109107
)
110108

111-
val dependencyGroupVersions = mapOf<String, String>()
109+
val dependencyGroupVersions = mapOf(
110+
"org.junit.jupiter" to libs.versions.junitJupiter.get(),
111+
)
112112

113113
configurations.all {
114114
resolutionStrategy {

gradle/libs.versions.toml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ jna = "5.19.1"
33
jnaVersionRange = "[5.0.0,)"
44
junixsocket = "2.10.1"
55
junixsocketVersionrange = "[2.4,3)"
6+
junitJupiter = "6.1.0"
7+
junitPlatform = "6.1.0"
68
kotlin = "2.4.0"
79
kotlinVersionrange = "[1.6,3)"
810
logback = "1.3.16"
@@ -31,10 +33,14 @@ okhttpMockwebserverJunit5 = { module = "com.squareup.okhttp3:mockwebserver3-juni
3133
okio = { module = "com.squareup.okio:okio", version.ref = "okio" }
3234
okioJvm = { module = "com.squareup.okio:okio-jvm", version.ref = "okio" }
3335
slf4j = { module = "org.slf4j:slf4j-api", version.ref = "slf4j" }
36+
junitJupiterApi = { module = "org.junit.jupiter:junit-jupiter-api", version.ref = "junitJupiter" }
37+
junitJupiterEngine = { module = "org.junit.jupiter:junit-jupiter-engine", version.ref = "junitJupiter" }
38+
junitPlatformLauncher = { module = "org.junit.platform:junit-platform-launcher", version.ref = "junitPlatform" }
3439

3540
[bundles]
3641
kotlin = ["kotlin", "kotlinCommon", "kotlinJdk7", "kotlinJdk8"]
3742
jna = ["jna", "jnaPlatform"]
3843
junixsocket = ["junixsocketCore", "junixsocketCommon"]
3944
okhttp = ["okhttp", "okhttpLoggingInterceptor", "okhttpMockwebserver", "okhttpMockwebserverJunit5"]
4045
okio = ["okio", "okioJvm"]
46+
junit = ["junitJupiterApi", "junitJupiterEngine", "junitPlatformLauncher"]

0 commit comments

Comments
 (0)