Click here to Skip to main content
15,909,605 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
Hey all

I've got a query on the following error I'm getting:
XML
<target name="test" depends="compile-tests">
<mkdir dir="${build.junit.reports}"/>
<junit>
<classpath refid="tests-classpath"/>
<formatter type="brief" usefile="false"/>
<batchtest fork="yes"                   todir="${build.junit.reports}"                   haltonerror="true"                   haltonfailure="true">
<fileset dir="${src.junit}"></fileset>
<include name="**/*Test*.java"></include>
<exclude name="**/AllTests.java"></exclude>
</batchtest>
</junit>
</target>

The Error I'm getting when running: ant clean dist
batchtest doesn't support the nested "include" element.

Can anyone tell me what the problem is?

Thanks,
Rudolf

UPDATE:
Resolved by OP himself. Posted resolution as an answer.
Posted
Updated 15-Feb-11 3:39am
v2

1 solution

So I found the solution to my problem...
Stupid tutorial uses a different version of junit which uses batchtest differently... not that they'll specify what junit version they were using.

<brachtest fork="yes" includes="**/*Test*.java" excludes="**/AllTests.java" todir="${build.junit.reports}" haltonerror="true"></brachtest>
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900