Skip to content

Commit

Permalink
Merge pull request junit-team#372 from matthewfarwell/doc-methodrule
Browse files Browse the repository at this point in the history
Several javadoc referred to MethodRule when they should have referred to...
  • Loading branch information
dsaff committed Feb 29, 2012
2 parents 59c686f + daa2e4d commit 1cec456
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 3 deletions.
2 changes: 2 additions & 0 deletions src/main/java/org/junit/rules/MethodRule.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
* <li>{@link Timeout}: cause test to fail after a set time</li>
* <li>{@link Verifier}: fail test if object state ends up incorrect</li>
* </ul>
*
* Note that {@link MethodRule} is now deprecated, you should be using {@link TestRule} instead.
*/
@Deprecated
public interface MethodRule {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/org/junit/rules/TestWatcher.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* private static String watchedLog;
*
* &#064;Rule
* public MethodRule watchman= new TestWatcher() {
* public TestRule watchman= new TestWatcher() {
* &#064;Override
* protected void failed(Description d) {
* watchedLog+= d + &quot;\n&quot;;
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/org/junit/rules/Timeout.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* public static String log;
*
* &#064;Rule
* public MethodRule globalTimeout= new Timeout(20);
* public TestRule globalTimeout= new Timeout(20);
*
* &#064;Test
* public void testInfiniteLoop1() {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/org/junit/rules/Verifier.java
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
* private ErrorLog errorLog = new ErrorLog();
*
* &#064;Rule
* public MethodRule verifier = new Verifier() {
* public TestRule verifier = new Verifier() {
* &#064;Override public void verify() {
* assertTrue(errorLog.isEmpty());
* }
Expand Down

0 comments on commit 1cec456

Please sign in to comment.