diff --git a/spring-boot-project/spring-boot-devtools/src/main/java/org/springframework/boot/devtools/restart/DefaultRestartInitializer.java b/spring-boot-project/spring-boot-devtools/src/main/java/org/springframework/boot/devtools/restart/DefaultRestartInitializer.java index 3526a02420..d9bf512180 100644 --- a/spring-boot-project/spring-boot-devtools/src/main/java/org/springframework/boot/devtools/restart/DefaultRestartInitializer.java +++ b/spring-boot-project/spring-boot-devtools/src/main/java/org/springframework/boot/devtools/restart/DefaultRestartInitializer.java @@ -37,6 +37,7 @@ public class DefaultRestartInitializer implements RestartInitializer { static { Set skipped = new LinkedHashSet<>(); skipped.add("org.junit.runners."); + skipped.add("org.junit.platform."); skipped.add("org.springframework.boot.test."); skipped.add("cucumber.runtime."); SKIPPED_STACK_ELEMENTS = Collections.unmodifiableSet(skipped); diff --git a/spring-boot-project/spring-boot-devtools/src/test/java/org/springframework/boot/devtools/restart/DefaultRestartInitializerTests.java b/spring-boot-project/spring-boot-devtools/src/test/java/org/springframework/boot/devtools/restart/DefaultRestartInitializerTests.java index ba8bb8e374..cd145725de 100644 --- a/spring-boot-project/spring-boot-devtools/src/test/java/org/springframework/boot/devtools/restart/DefaultRestartInitializerTests.java +++ b/spring-boot-project/spring-boot-devtools/src/test/java/org/springframework/boot/devtools/restart/DefaultRestartInitializerTests.java @@ -36,6 +36,11 @@ public class DefaultRestartInitializerTests { testSkippedStacks("org.junit.runners.Something"); } + @Test + public void jUnit5StackShouldReturnNull() { + testSkippedStacks("org.junit.platform.Something"); + } + @Test public void springTestStackShouldReturnNull() { testSkippedStacks("org.springframework.boot.test.Something");