Skip to content
Snippets Groups Projects
Commit 813ded32 authored by gmantele's avatar gmantele
Browse files

TAP: Execute all JUnit tests before building the TAP library. At any JUnit...

TAP: Execute all JUnit tests before building the TAP library. At any JUnit failure, the build is canceled
+ Update the version number for the generated JARs.
parent 2aaef7da
No related branches found
No related tags found
No related merge requests found
......@@ -2,7 +2,7 @@
<!DOCTYPE project>
<project name="adql" basedir="." default="buildLib">
<property name="version" value="1.1" />
<property name="version" value="1.2" />
<property name="srcDir" value="src" />
<property name="compileDir" value="antBuild" />
......
......@@ -2,7 +2,7 @@
<!DOCTYPE project>
<project name="tap" basedir="." default="buildLib">
<property name="version" value="1.0" />
<property name="version" value="1.1" />
<property name="srcDir" value="src" />
<property name="compileDir" value="antBuild" />
......@@ -28,14 +28,29 @@
<fail message="The property SERVLET-API must be set! It provides the path toward a directory or a JAR which contains all classes inside javax.servlet.">
<condition><not><isset property="SERVLET-API"/></not></condition>
</fail>
<fail message="The property JUNIT-API must be set! It provides the path toward a directory or a JAR which contains all classes needed to use JUnit.">
<condition><not><isset property="JUNIT-API"/></not></condition>
</fail>
<path id="tap.classpath">
<pathelement location="${uploadUtilsJar}" />
<pathelement location="${CATALINA}" />
<pathelement location="${SERVLET-API}" />
<pathelement path="${JUNIT-API}" />
</path>
<echo>TAP LIBRARY VERSION = ${version}</echo>
<!-- Define the classpath which includes the junit.jar and the classes after compiling-->
<path id="junit.class.path">
<pathelement path="${JUNIT-API}" />
<pathelement location="/opt/Java_Libraries/postgresql-9.3-1100.jdbc3.jar" />
<pathelement location="${jsonJar}" />
<pathelement location="${uploadUtilsJar}" />
<pathelement location="${CATALINA}" />
<pathelement location="${SERVLET-API}" />
<pathelement location="bin" />
</path>
<echo>TAP LIBRARY VERSION = ${version}</echo>
<!-- BUILD ALL TASK -->
<target name="buildAll" depends="buildLibAndSrc,buildJavadoc"
......@@ -46,7 +61,16 @@
<target name="cleanAll" depends="clean,cleanJavadoc" description="Delete all files generated by this ANT file for the set version." />
<!-- LIB & SOURCES -->
<target name="clean" description="Delete the JARs for the library (classes) and for its sources for the set version.">
<target name="junitValidation" description="Executes all JUnit tests before building the library and stop ANT at any error.">
<junit printsummary="on" fork="yes" haltonfailure="yes">
<classpath refid="junit.class.path" />
<test name="tap.config.AllTests" outfile="testReports">
<formatter type="plain" usefile="yes" />
</test>
</junit>
</target>
<target name="clean" depends="junitValidation" description="Delete the JARs for the library (classes) and for its sources for the set version.">
<delete file="${libJarFile}" failonerror="false" />
<delete file="${srcJarFile}" failonerror="false" />
<delete dir="${compileDir}" failonerror="false" />
......
......@@ -2,7 +2,7 @@
<!DOCTYPE project>
<project name="uws" basedir="." default="buildLib">
<property name="version" value="4.0" />
<property name="version" value="4.1" />
<property name="srcDir" value="src" />
<property name="compileDir" value="antBuild" />
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment