junit与ant测试的问题 [junit] TEST se.testsuit.AllTests FAILED我想它应该是类吧?这个se.testsuit.AllTests在jb下已经编译过了,也通过测试了,现在想在ant下调试一下! 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 <junit> <test name="se.testsuit.AllTests" haltonfailure="no" outfile="result"/> </junit>这样的信息不全啊!兄弟!一般来说,应该有个value值来指定具体的位置,可是你这里看不出来!你可以找点ANT的书来看看,把这个target的任务补全来! 我的脚本中关于junit的一部分。<target name="runTest" depends="init"> <delete> <fileset dir="${testReport}" includes="**/*.*"/> </delete> <junit fork="on"> <classpath refid="libClassPath"/> <classpath> <pathelement location="${appPath}/WEB-INF/classes"/> </classpath> <formatter type="xml"/> <!--<test name="fixturetutorial.TestDataModule1" haltonfailure="no" outfile="result"/>--> <batchtest fork="yes" todir="${testReport}"> <fileset dir="${appPath}/WEB-INF/classes"> <include name="**/PortalTestAll.class"/> </fileset> </batchtest> </junit> <junitreport todir="${testReport}"> <fileset dir="${testReport}"> <include name="TEST-*.xml"/> </fileset> <report format="frames" todir="${testReport}"/> </junitreport></target> 我认为得把单个测试的类放在classpath中 <classpath> <pathelement location="${appPath}/WEB-INF/classes"/> <pathelement location="......./AllTests.class"> <!--或者你这个class所在的jar包--> </classpath> 问一个Quartz时间表达式的问题 空格分割 webservice客户端代码执行错误 java 多媒体播放功能问题 如何用hibernatte实现一个表中的一个字段对多个表的多对一映射?并且由一个控制字段控制? 这个问题困扰我很长时间了,还是不是很清楚 有个spring的问题,请教高手,高分谢谢! tomcat-4.1.30出错?(解决马上给分) logic:iterate struts 标签使用问题? 这个编码问题怎么弄?? ant高手看过来 兄弟们呀,看看过段代码,用程序写一个Mysql 备份功能,老得到一个空备份文件谢谢
<test name="se.testsuit.AllTests" haltonfailure="no" outfile="result"/>
</junit>
这样的信息不全啊!兄弟!
一般来说,应该有个value值来指定具体的位置,可是你这里看不出来!
你可以找点ANT的书来看看,把这个target的任务补全来!
<target name="runTest" depends="init">
<delete>
<fileset dir="${testReport}" includes="**/*.*"/>
</delete>
<junit fork="on">
<classpath refid="libClassPath"/>
<classpath>
<pathelement location="${appPath}/WEB-INF/classes"/>
</classpath>
<formatter type="xml"/>
<!--<test name="fixturetutorial.TestDataModule1" haltonfailure="no" outfile="result"/>-->
<batchtest fork="yes" todir="${testReport}">
<fileset dir="${appPath}/WEB-INF/classes">
<include name="**/PortalTestAll.class"/>
</fileset>
</batchtest>
</junit>
<junitreport todir="${testReport}">
<fileset dir="${testReport}">
<include name="TEST-*.xml"/>
</fileset>
<report format="frames" todir="${testReport}"/>
</junitreport>
</target>
<classpath>
<pathelement location="${appPath}/WEB-INF/classes"/>
<pathelement location="......./AllTests.class">
<!--或者你这个class所在的jar包-->
</classpath>