Browse Source

Ensure that JUnit Jupiter tests are executed during build

After the upgrade to JUnit Jupiter 5.0 M3, JUnit Jupiter tests in the
Spring build were no longer executed due to the introduction of a
default test class name pattern.

This commit addresses this issue by making use of the
@IncludeClassNamePatterns to specify that *TestCase test classes should
be executed within the org.springframework.test.context.junit.jupiter
package.
pull/1287/head
Sam Brannen 8 years ago
parent
commit
e4a599f961
  1. 2
      spring-test/src/test/java/org/springframework/test/context/junit/SpringJUnitJupiterTestSuite.java

2
spring-test/src/test/java/org/springframework/test/context/junit/SpringJUnitJupiterTestSuite.java

@ -16,6 +16,7 @@ @@ -16,6 +16,7 @@
package org.springframework.test.context.junit;
import org.junit.platform.runner.IncludeClassNamePatterns;
import org.junit.platform.runner.IncludeEngines;
import org.junit.platform.runner.JUnitPlatform;
import org.junit.platform.runner.SelectPackages;
@ -47,6 +48,7 @@ import org.junit.runner.RunWith; @@ -47,6 +48,7 @@ import org.junit.runner.RunWith;
@RunWith(JUnitPlatform.class)
@IncludeEngines("junit-jupiter")
@SelectPackages("org.springframework.test.context.junit.jupiter")
@IncludeClassNamePatterns("^.*TestCase$")
@UseTechnicalNames
public class SpringJUnitJupiterTestSuite {
}

Loading…
Cancel
Save