我正在使用Junit 4.4和Ant 1.7。如果测试用例失败并出现错误(例如,因为某个方法引发了意外的异常),我没有得到有关错误的详细信息。JUnit没有提供关于“错误”的信息
我的build.xml文件看起来是这样的:
<target name="test" depends="compile">
<junit printsummary="withOutAndErr" filtertrace="no" fork="yes" haltonfailure="yes" showoutput="yes">
<classpath refid="project.run.path"/>
<test name="a.b.c.test.TestThingee1"/>
<test name="a.b.c.test.NoSuchTest"/>
</junit>
</target>
当我运行 “蚂蚁测试” 它说,(例如)2测试运行,0失败,1个错误。它没有说“没有NoSuchTest这样的测试”,尽管这是完全合理的,并且让我找出错误的原因。
谢谢!
-Dan
+1我只是有这个错误,这工作完美。谢谢! – 2010-05-04 17:11:27