I had the same problem - had to go back to JUnit 3.2 and then it worked fine.
Ken > -----Original Message----- > From: Brendon Mclean [mailto:[EMAIL PROTECTED] > Sent: Thursday, January 25, 2001 1:35 PM > To: [EMAIL PROTECTED] > Subject: Ant 1.2 not compatible with JUnit 3.5 > > > Hi, > > Not being involved in the development of Ant and its optional > libraries I > cannot be sure, but I think that Ant 1.2 is not compatible > with JUnit 3.5 > (18-Jan-2001). I am getting an AbstractMethodError when > using the built in > option junit task. This only occurs when an > assert() is called in from TestCase instance. The stack trace is as > follows: > > java.lang.AbstractMethodError > at junit.framework.TestResult.addFailure(TestResult.java:46) > at junit.framework.TestResult.runProtected(TestResult.java:127) > at junit.framework.TestResult.run(TestResult.java:109) > at junit.framework.TestCase.run(TestCase.java:121) > at junit.framework.TestSuite.runTest(TestSuite.java:157) > at junit.framework.TestSuite.run(TestSuite.java:152) > at > org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.r > un(JUnitTestRu > nner.java:202) > at > org.apache.tools.ant.taskdefs.optional.junit.JUnitTask.execute > (JUnitTask.jav > a:268) > at org.apache.tools.ant.Target.execute(Target.java:142) > at org.apache.tools.ant.Project.runTarget(Project.java:818) > at org.apache.tools.ant.Project.executeTarget(Project.java:532) > at org.apache.tools.ant.Project.executeTargets(Project.java:506) > at org.apache.tools.ant.Main.runBuild(Main.java:420) > at org.apache.tools.ant.Main.main(Main.java:149) > > I went to the JUnit section of SourceForge. This is a diff > between the > TestResult interface of JUnit 3.4 and 3.5: > > >version 1.1, 2000/12/03 14:36:19 (3.4) > >---------------------------------------- > >/** > >* A failure occurred. > >*/ > >public void addFailure(Test test, Throwable t); > > >version 1.2, 2001/01/09 23:39:50 (3.5) > >---------------------------------------- > >/** > >* A failure occurred. > >*/ > >public void addFailure(Test test, AssertionFailedError t); > > I think this could be the problem. Once again I'm sure > someone knows about > this already and is working on it right now, but I could not > be sure. I did > search the mailing lists and web site before sending this > email but I could > not find anything mentioning any incompatibility between the various > versions. > > Anyway, hope this helps someone. Let me know if I have made > an horrendously > wrong assumptions > > Cheers > Brendon Mclean > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] >
