Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <target name="compile-junit"
- depends="compile, prepare-junit">
- <echo message="ANT_HOME: ${env.ANT_HOME}"/>
- <javac srcdir="${test.dir}"
- destdir="${build.test}"
- debug="true"
- includeantruntime="true"
- source="1.6"
- target="1.6">
- <classpath refid="junit.classpath"/>
- </javac>
- </target>
- <target name="test" depends="compile-junit"
- description="Run junit test cases">
- <junit printsummary="yes"
- fork="yes"
- haltonfailure="yes"
- errorProperty="test.failed"
- failureProperty="test.failed">
- <assertions><enable/></assertions>
- <classpath refid="junit.classpath"/>
- <formatter type="plain" usefile="false"/>
- <formatter type="xml" usefile="true"/>
- <jvmarg value="-Ddebug=true"/>
- <batchtest todir="${build.reports}">
- <fileset dir="${build.test}"
- includes="**/*Test.class"/>
- </batchtest>
- </junit>
- <fail message="Junit tests failed. Check log and/or reports."
- if="test.failed"/>
- </target>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement