We should add testRuntimeOnly 'org.junit.platform:junit-platform-launcher' to the classpath See https://github.com/junit-team/junit5/issues/4335