Skip to content

Commit be288f1

Browse files
committed
chore: Update JUnit 4 -> 6
1 parent 01e6a8d commit be288f1

9 files changed

Lines changed: 412 additions & 441 deletions

File tree

build.gradle

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@ repositories {
1717
}
1818

1919
dependencies {
20-
testImplementation 'junit:junit:4.13.2'
20+
testImplementation 'org.junit.jupiter:junit-jupiter:6.0.3'
21+
testRuntimeOnly 'org.junit.platform:junit-platform-launcher:6.0.3'
2122
implementation "org.threadly:threadly:$threadlyVersion"
2223
}
2324

@@ -36,6 +37,8 @@ checkstyle {
3637
def testMode = project.findProperty('testMode') ?: 'default'
3738

3839
test {
40+
useJUnitPlatform()
41+
3942
switch (testMode) {
4043
case 'slow':
4144
maxParallelForks = 1

src/test/java/org/threadly/Repeat.java

Lines changed: 0 additions & 15 deletions
This file was deleted.

src/test/java/org/threadly/RepeatRule.java

Lines changed: 0 additions & 35 deletions
This file was deleted.

src/test/java/org/threadly/ThreadlyTester.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
import java.lang.Thread.UncaughtExceptionHandler;
44

5-
import org.junit.Rule;
65
import org.threadly.util.ExceptionHandler;
76
import org.threadly.util.ExceptionUtils;
87
import org.threadly.util.StringUtils;
@@ -131,9 +130,6 @@ public static void setIgnoreExceptionHandler() {
131130
ExceptionUtils.setDefaultExceptionHandler(ieh);
132131
}
133132

134-
@Rule
135-
public RepeatRule repeatRule = new RepeatRule();
136-
137133
private static class IgnoreExceptionHandler implements UncaughtExceptionHandler,
138134
ExceptionHandler {
139135
@Override

0 commit comments

Comments
 (0)