Proper running unittest.
authorAdam Dickmeiss <adam@indexdata.dk>
Mon, 7 Apr 2008 12:54:31 +0000 (14:54 +0200)
committerAdam Dickmeiss <adam@indexdata.dk>
Mon, 7 Apr 2008 12:54:31 +0000 (14:54 +0200)
bin/.DS_Store [deleted file]
build.xml

diff --git a/bin/.DS_Store b/bin/.DS_Store
deleted file mode 100644 (file)
index 9520a6f..0000000
Binary files a/bin/.DS_Store and /dev/null differ
index 6b7e985..3ad9842 100644 (file)
--- a/build.xml
+++ b/build.xml
     </javac>
   </target>
 
-  <target name="test" depends="compile" description="test the code">
+  <target name="compile-test" depends="compile" description="compile test the code">
     <javac srcdir="${test}" destdir="${bin}">
        <classpath refid="project.classpath"/>
     </javac>
   </target>
 
+  <!-- LD_LIBRARY_PATH=libyaz4j/lib java -cp bin:dependencies/JUnit-4.3.1/junit-4.3.1.jar org.junit.runner.JUnitCore yaz4jtest.ConnectionTest -->
+
+  <target name="unit-test" depends="compile-test" description="test the code">
+    <junit fork="on">
+       <env key="LD_LIBRARY_PATH" value="libyaz4j/lib"/>
+       <classpath refid="project.classpath"/>
+       <test name="yaz4jtest.ConnectionTest"/>
+    </junit>
+  </target>
+
   <target name="build-dist" depends="compile" description="generate the distribution">
     <mkdir dir="${distributions}/${version}"/>
     <jar jarfile="${distributions}/${version}/yaz4j.jar" basedir="${bin}">