ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From co...@apache.org
Subject cvs commit: jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/junit BriefJUnitResultFormatter.java
Date Sat, 05 May 2001 14:02:51 GMT
conor       01/05/05 07:02:51

  Modified:    src/main/org/apache/tools/ant/taskdefs/optional/junit
                        BriefJUnitResultFormatter.java
  Log:
  Add in the addFailure method for later versions of JUnit
  copied from PlainFormatter
  
  Revision  Changes    Path
  1.2       +15 -4     jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/junit/BriefJUnitResultFormatter.java
  
  Index: BriefJUnitResultFormatter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/junit/BriefJUnitResultFormatter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- BriefJUnitResultFormatter.java	2001/05/04 08:03:53	1.1
  +++ BriefJUnitResultFormatter.java	2001/05/05 14:02:50	1.2
  @@ -198,12 +198,23 @@
       }
   
       /**
  -     * A test failed.
  +     * Interface TestListener for JUnit <= 3.4.
  +     *
  +     * <p>A Test failed.
        */
  -    public void addFailure(Test test, AssertionFailedError failure) {
  -        formatError("\tFAILED", test, failure);
  +    public void addFailure(Test test, Throwable t) {
  +        formatError("\tFAILED", test, t);
       }
  -    
  +
  +    /**
  +     * Interface TestListener for JUnit &gt; 3.4.
  +     *
  +     * <p>A Test failed.
  +     */
  +    public void addFailure(Test test, AssertionFailedError t) {
  +        addFailure(test, (Throwable) t);
  +    }
  +
       /**
        * A test caused an error.
        */
  
  
  

Mime
View raw message