+ <target name="build-test" depends="init,build">
+ <fail message="Please build 'javase' first">
+ <condition>
+ <not>
+ <available file="../javase/javase.jar" type="file"/>
+ </not>
+ </condition>
+ </fail>
+ <mkdir dir="build-test"/>
+ <javac srcdir="test/src"
+ destdir="build-test"
+ debug="true"
+ deprecation="true">
+ <classpath>
+ <pathelement location="core.jar"/>
+ <pathelement location="../javase/javase.jar"/>
+ <pathelement location="lib/junit.jar"/>
+ </classpath>
+ </javac>
+ </target>
+
+ <target name="test-blackbox" depends="build-test">
+ <parallel failonany="true">
+ <antcall target="test-blackbox-subset">
+ <param name="subdir" value="datamatrix"/>
+ </antcall>
+ <antcall target="test-blackbox-subset">
+ <param name="subdir" value="negative"/>
+ </antcall>
+ <antcall target="test-blackbox-subset">
+ <param name="subdir" value="oned"/>
+ </antcall>
+ <antcall target="test-blackbox-subset">
+ <param name="subdir" value="qrcode"/>
+ </antcall>
+ </parallel>
+ </target>
+
+ <target name="test-blackbox-subset">
+ <junit printsummary="on" haltonfailure="on" haltonerror="on" fork="true" dir=".">
+ <formatter type="plain" usefile="false"/>
+ <classpath>
+ <pathelement location="core.jar"/>
+ <pathelement location="build-test"/>
+ <pathelement location="../javase/javase.jar"/>
+ <pathelement location="lib/junit.jar"/>
+ </classpath>
+ <assertions>
+ <enable/>
+ </assertions>
+ <batchtest>
+ <fileset dir="test/src">
+ <include name="**/${subdir}/*BlackBox*TestCase.java"/>
+ <exclude name="**/Abstract*.java"/>
+ </fileset>
+ </batchtest>
+ </junit>
+ </target>
+
+ <target name="test-unit" depends="build-test">
+ <junit printsummary="on" haltonfailure="on" haltonerror="on" fork="true" dir=".">
+ <formatter type="plain" usefile="false"/>
+ <classpath>
+ <pathelement location="core.jar"/>
+ <pathelement location="build-test"/>
+ <pathelement location="../javase/javase.jar"/>
+ <pathelement location="lib/junit.jar"/>
+ </classpath>
+ <assertions>
+ <enable/>
+ </assertions>
+ <batchtest>
+ <fileset dir="test/src">
+ <include name="**/*TestCase.java"/>
+ <exclude name="**/*BlackBox*TestCase.java"/>
+ <exclude name="**/Abstract*.java"/>
+ </fileset>
+ </batchtest>
+ </junit>
+ </target>
+
+ <target name="test" depends="test-unit,test-blackbox"/>
+