Skip to content

Commit dbbb9a0

Browse files
committed
Update JUnit to version 5.13.1 and make usage more idiomatic
1 parent 2498f04 commit dbbb9a0

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

build-scripts/component-common.gradle

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,10 @@ kotlin {
4343
}
4444

4545
dependencies {
46-
testImplementation libs.junit.vintage
46+
testImplementation platform(libs.junit.bom)
47+
testImplementation libs.junit4
48+
testRuntimeOnly libs.junit.vintage
49+
testRuntimeOnly libs.junit.platform.launcher
4750
testImplementation libs.testing.mockito
4851
testImplementation libs.testing.robolectric
4952

gradle/libs.versions.toml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,8 @@ androidx-test-runner = "1.6.2"
3939
androidx-work = "2.10.1"
4040

4141
# Third Party Testing
42-
junit = "5.12.0"
42+
junit4 = "4.13.2"
43+
junit5 = "5.13.1"
4344
mockito = "5.17.0"
4445
robolectric = "4.14.1"
4546

@@ -87,7 +88,11 @@ test-espresso-core = { group = "androidx.test.espresso", name = "espresso-core",
8788

8889

8990
# Third Party Testing
90-
junit-vintage = { group = "org.junit.vintage", name = "junit-vintage-engine", version.ref = "junit" }
91+
junit4 = { group = "junit", name = "junit", version.ref = "junit4" }
92+
junit-bom = { group = "org.junit", name = "junit-bom", version.ref = "junit5" }
93+
junit-jupiter = { group = "org.junit.jupiter", name = "junit-jupiter" }
94+
junit-platform-launcher = { group = "org.junit.platform", name = "junit-platform-launcher" }
95+
junit-vintage = { group = "org.junit.vintage", name = "junit-vintage-engine" }
9196
testing-mockito = { group = "org.mockito", name = "mockito-core", version.ref = "mockito" }
9297
testing-robolectric = { group = "org.robolectric", name = "robolectric", version.ref = "robolectric" }
9398

0 commit comments

Comments
 (0)