<jar jarfile="core.jar" basedir="build" level="9"/>
</target>
- <target name="test" depends="init,build">
+ <target name="build-test" depends="init,build">
<fail message="Please build 'javase' first">
<condition>
<not>
<pathelement location="lib/junit.jar"/>
</classpath>
</javac>
+ </target>
+
+ <target name="test-blackbox" depends="build-test">
<junit printsummary="on" haltonfailure="on" haltonerror="on" fork="true" dir=".">
<formatter type="plain" usefile="false"/>
<classpath>
</assertions>
<batchtest>
<fileset dir="test/src">
- <include name="**/*TestCase.java"/>
+ <include name="**/*BlackBox*TestCase.java"/>
<exclude name="com/google/zxing/common/AbstractBlackBoxTestCase.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="build"/>
+ <pathelement location="build-test"/>
+ <pathelement location="../javase/javase.jar"/>
+ <pathelement location="lib/junit.jar"/>
+ </classpath>
+ <assertions>
+ <enable/>
+ </assertions>
+ <batchtest>
+ <fileset dir="test/src">
+ <exclude name="**/*BlackBox*TestCase.java"/>
+ </fileset>
+ </batchtest>
+ </junit>
+ </target>
+
+ <target name="test" depends="test-unit,test-blackbox"/>
+
<target name="clean">
<delete dir="build"/>
<delete dir="build-test"/>