Skip to content

Commit e9649b3

Browse files
committed
added JUnit 4.5 compatibility note
1 parent 582c564 commit e9649b3

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

org.springframework.test/src/main/java/org/springframework/test/context/junit4/SpringJUnit4ClassRunner.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,11 @@
5454
* <li>{@link org.springframework.test.annotation.IfProfileValue @IfProfileValue}</li>
5555
* </ul>
5656
*
57+
* <p><b>NOTE:</b> As of Spring 3.0 M1, SpringJUnit4ClassRunner requires
58+
* JUnit 4.5, while internally still being based on JUnit 4.4 SPI.
59+
* This will be rewritten based on JUnit 4.5's BlockJUnit4ClassRunner
60+
* in a later Spring 3.0 release.
61+
*
5762
* @author Sam Brannen
5863
* @author Juergen Hoeller
5964
* @since 2.5

org.springframework.test/src/main/java/org/springframework/test/context/junit4/SpringMethodRoadie.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,10 @@
2929

3030
import org.apache.commons.logging.Log;
3131
import org.apache.commons.logging.LogFactory;
32+
import org.junit.internal.AssumptionViolatedException;
3233
import org.junit.runner.Description;
3334
import org.junit.runner.notification.Failure;
3435
import org.junit.runner.notification.RunNotifier;
35-
import org.junit.internal.AssumptionViolatedException;
3636

3737
import org.springframework.test.annotation.Repeat;
3838
import org.springframework.test.annotation.Timed;
@@ -98,6 +98,7 @@ public SpringMethodRoadie(TestContextManager testContextManager, Object testInst
9898
this.description = description;
9999
}
100100

101+
101102
/**
102103
* Runs the <em>test</em>, including notification of events to the
103104
* {@link RunNotifier} and {@link TestContextManager} as well as proper
@@ -333,6 +334,7 @@ public void run() {
333334
runTestMethod();
334335
}
335336
catch (FailedBefore ex) {
337+
// ignore
336338
}
337339
finally {
338340
runAfters();

0 commit comments

Comments
 (0)