forked from I2P_Developers/i2p.i2p
allow setting hamcrest and junit locations with properties
Defaults to the ant library path (the previously hardcoded path) if not set.
This commit is contained in:
@ -18,7 +18,7 @@ wrapperdocs.url=http://wrapper.tanukisoftware.com/jdoc/
|
|||||||
i2pdocs.url=http://docs.i2p-projekt.de/javadoc/
|
i2pdocs.url=http://docs.i2p-projekt.de/javadoc/
|
||||||
junitdocs.url=http://junit.org/apidocs/
|
junitdocs.url=http://junit.org/apidocs/
|
||||||
# This will go in the jar manifests
|
# This will go in the jar manifests
|
||||||
build.built-by=unknown
|
build.built-by=unknown
|
||||||
|
|
||||||
# filename of the sloccount report
|
# filename of the sloccount report
|
||||||
sloccount.report.file=sloccount.sc
|
sloccount.report.file=sloccount.sc
|
||||||
@ -44,6 +44,7 @@ require.gettext=true
|
|||||||
# This one keeps gcj a lot quieter
|
# This one keeps gcj a lot quieter
|
||||||
#javac.compilerargs=-warn:-unchecked,raw,unused,serial
|
#javac.compilerargs=-warn:-unchecked,raw,unused,serial
|
||||||
|
|
||||||
|
### UnitTests ##
|
||||||
# Location of the libraries required for the ScalaTest tests.
|
# Location of the libraries required for the ScalaTest tests.
|
||||||
# Define this in override.properties or pass in on the command line.
|
# Define this in override.properties or pass in on the command line.
|
||||||
# The directory must contain the following library names:
|
# The directory must contain the following library names:
|
||||||
@ -53,6 +54,18 @@ require.gettext=true
|
|||||||
# scalatest.jar
|
# scalatest.jar
|
||||||
#scalatest.libs=/PATH/TO/SCALATEST/lib
|
#scalatest.libs=/PATH/TO/SCALATEST/lib
|
||||||
|
|
||||||
|
# Location of the junit libraries
|
||||||
|
# Defaults to the ant library path if not set.
|
||||||
|
# If set, this must point to a directory that contains the files
|
||||||
|
# junit.jar and junit4.jar
|
||||||
|
#junit.home=
|
||||||
|
|
||||||
|
# Location of the hamcrest libraries
|
||||||
|
# Defaults to the ant library path if not set
|
||||||
|
# If set, this must point to a directory containing the files
|
||||||
|
# hamcrest-core.jar, hamcrest-library.jar, and hamcrest-integration.jar
|
||||||
|
#hamcrest.home=
|
||||||
|
|
||||||
# Optional properties used in tests to enable additional tools.
|
# Optional properties used in tests to enable additional tools.
|
||||||
#with.cobertura=/PATH/TO/cobertura.jar
|
#with.cobertura=/PATH/TO/cobertura.jar
|
||||||
#with.clover=/PATH/TO/clover.jar
|
#with.clover=/PATH/TO/clover.jar
|
||||||
|
@ -98,10 +98,20 @@
|
|||||||
<target name="junit.compileTest" depends="compile">
|
<target name="junit.compileTest" depends="compile">
|
||||||
<mkdir dir="./build" />
|
<mkdir dir="./build" />
|
||||||
<mkdir dir="./build/obj" />
|
<mkdir dir="./build/obj" />
|
||||||
<!-- junit and hamcrest classes should be in ant runtime -->
|
<!-- set hamcrest and junit homes to the old default unless overridden elsewhere -->
|
||||||
|
<property name="hamcrest.home" value="${ant.home}/lib/" />
|
||||||
|
<property name="junit.home" value="${ant.home}/lib/" />
|
||||||
<javac srcdir="./test/junit" debug="true" source="1.5" target="1.5" deprecation="on"
|
<javac srcdir="./test/junit" debug="true" source="1.5" target="1.5" deprecation="on"
|
||||||
includeAntRuntime="true"
|
includeAntRuntime="true"
|
||||||
destdir="./build/obj" >
|
destdir="./build/obj" >
|
||||||
|
<classpath>
|
||||||
|
<pathelement path="${classpath}" />
|
||||||
|
<pathelement location="${hamcrest.home}/hamcrest-core.jar" />
|
||||||
|
<pathelement location="${hamcrest.home}/hamcrest-library.jar" />
|
||||||
|
<pathelement location="${hamcrest.home}/hamcrest-integration.jar" />
|
||||||
|
<pathelement location="${junit.home}/junit.jar" />
|
||||||
|
<pathelement location="${junit.home}/junit4.jar" />
|
||||||
|
</classpath>
|
||||||
<compilerarg line="${javac.compilerargs}" />
|
<compilerarg line="${javac.compilerargs}" />
|
||||||
</javac>
|
</javac>
|
||||||
</target>
|
</target>
|
||||||
@ -191,6 +201,8 @@
|
|||||||
<replace dir="../../reports/core/scalatest/" token="${host.name}" value="${host.fakename}"/>
|
<replace dir="../../reports/core/scalatest/" token="${host.name}" value="${host.fakename}"/>
|
||||||
</target>
|
</target>
|
||||||
<target name="junit.test" depends="clean, junit.compileTest, prepareTest">
|
<target name="junit.test" depends="clean, junit.compileTest, prepareTest">
|
||||||
|
<property name="hamcrest.home" value="${ant.home}/lib/" />
|
||||||
|
<property name="junit.home" value="${ant.home}/lib/" />
|
||||||
<mkdir dir="../../reports/core/junit/" />
|
<mkdir dir="../../reports/core/junit/" />
|
||||||
<delete>
|
<delete>
|
||||||
<fileset dir="../../reports/core/junit">
|
<fileset dir="../../reports/core/junit">
|
||||||
@ -201,9 +213,11 @@
|
|||||||
<sysproperty key="net.sourceforge.cobertura.datafile" file="./cobertura.ser" />
|
<sysproperty key="net.sourceforge.cobertura.datafile" file="./cobertura.ser" />
|
||||||
<classpath>
|
<classpath>
|
||||||
<pathelement path="${classpath}" />
|
<pathelement path="${classpath}" />
|
||||||
<pathelement location="${ant.home}/lib/hamcrest-core.jar" />
|
<pathelement location="${hamcrest.home}/hamcrest-core.jar" />
|
||||||
<pathelement location="${ant.home}/lib/hamcrest-library.jar" />
|
<pathelement location="${hamcrest.home}/hamcrest-library.jar" />
|
||||||
<pathelement location="${ant.home}/lib/hamcrest-integration.jar" />
|
<pathelement location="${hamcrest.home}/hamcrest-integration.jar" />
|
||||||
|
<pathelement location="${junit.home}/junit.jar" />
|
||||||
|
<pathelement location="${junit.home}/junit4.jar" />
|
||||||
<pathelement location="./build/obj_cobertura" />
|
<pathelement location="./build/obj_cobertura" />
|
||||||
<pathelement location="./build/obj" />
|
<pathelement location="./build/obj" />
|
||||||
<pathelement location="../../build/jbigi.jar" />
|
<pathelement location="../../build/jbigi.jar" />
|
||||||
|
@ -119,13 +119,24 @@
|
|||||||
</classpath>
|
</classpath>
|
||||||
</scalac>
|
</scalac>
|
||||||
</target>
|
</target>
|
||||||
|
|
||||||
<target name="junit.compileTest" depends="builddeptest, compile">
|
<target name="junit.compileTest" depends="builddeptest, compile">
|
||||||
<mkdir dir="./build" />
|
<mkdir dir="./build" />
|
||||||
<mkdir dir="./build/obj" />
|
<mkdir dir="./build/obj" />
|
||||||
<!-- junit classes are in ant runtime -->
|
<!-- set hamcrest and junit homes to the old default unless overridden elsewhere -->
|
||||||
|
<property name="hamcrest.home" value="${ant.home}/lib/" />
|
||||||
|
<property name="junit.home" value="${ant.home}/lib/" />
|
||||||
<javac srcdir="./test/junit" debug="true" source="1.5" target="1.5" deprecation="on"
|
<javac srcdir="./test/junit" debug="true" source="1.5" target="1.5" deprecation="on"
|
||||||
includeAntRuntime="true"
|
includeAntRuntime="true"
|
||||||
destdir="./build/obj" classpath="../../core/java/build/i2ptest.jar" >
|
destdir="./build/obj">
|
||||||
|
<classpath>
|
||||||
|
<pathelement location="${hamcrest.home}/hamcrest-core.jar" />
|
||||||
|
<pathelement location="${hamcrest.home}/hamcrest-library.jar" />
|
||||||
|
<pathelement location="${hamcrest.home}/hamcrest-integration.jar" />
|
||||||
|
<pathelement location="$junit.home}/junit.jar" />
|
||||||
|
<pathelement location="$junit.home}/junit4.jar" />
|
||||||
|
<pathelement location="../../core/java/build/i2ptest.jar" />
|
||||||
|
</classpath>
|
||||||
<compilerarg line="${javac.compilerargs}" />
|
<compilerarg line="${javac.compilerargs}" />
|
||||||
</javac>
|
</javac>
|
||||||
</target>
|
</target>
|
||||||
|
Reference in New Issue
Block a user