vmassol 2003/02/06 00:55:39
Modified: documentation build.xml
samples/servlet/src/scripts/share build.xml
samples/servlet build.xml
. gump.xml build-common.xml
framework build.xml
Log:
Added build stuff for generating clover reports. We are almost there!
Revision Changes Path
1.34 +2 -0 jakarta-cactus/documentation/build.xml
Index: build.xml
===================================================================
RCS file: /home/cvs/jakarta-cactus/documentation/build.xml,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -r1.33 -r1.34
--- build.xml 3 Feb 2003 08:36:04 -0000 1.33
+++ build.xml 6 Feb 2003 08:55:39 -0000 1.34
@@ -81,6 +81,8 @@
-->
<target name="init" depends="init.common,properties">
+ <echo>clover.enable (optional) = ${clover.enable}</echo>
+
<xmlcatalog id="documentation.dtds">
<dtd publicId="-//Apache Software Foundation//DTD Cactus Navigation
V1.0//EN"
location="${doc.dtd.dir}/navigation-v10.dtd"/>
1.3 +2 -0 jakarta-cactus/samples/servlet/src/scripts/share/build.xml
Index: build.xml
===================================================================
RCS file: /home/cvs/jakarta-cactus/samples/servlet/src/scripts/share/build.xml,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- build.xml 3 Feb 2003 10:52:47 -0000 1.2
+++ build.xml 6 Feb 2003 08:55:39 -0000 1.3
@@ -129,6 +129,7 @@
<path id="cactus.classpath">
<pathelement location="${target.classes.java.dir}"/>
+ @cactus.clover.pathelement@
<path refid="project.classpath"/>
</path>
@@ -181,6 +182,7 @@
<fail message="Missing property or property pointing to an invalid file
(check your build.properties file)"/>
</target>
+
<!--
========================================================================
Initialize the build. Must be called by all targets
1.3 +43 -5 jakarta-cactus/samples/servlet/build.xml
Index: build.xml
===================================================================
RCS file: /home/cvs/jakarta-cactus/samples/servlet/build.xml,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- build.xml 3 Feb 2003 10:52:47 -0000 1.2
+++ build.xml 6 Feb 2003 08:55:39 -0000 1.3
@@ -111,6 +111,7 @@
depends="init.common,properties,check.properties">
<echo>cactus.port (optional) = ${cactus.port}</echo>
+ <echo>clover.enable (optional) = ${clover.enable}</echo>
<!-- Custom Ant task definition used in the test targets below.
It is used for computing the "-D" parameter list
@@ -184,9 +185,8 @@
<antcall target="sample.replace.${j2ee.api}"/>
</target>
-
- <target name="sample" depends="init"
- description="Generate the sample application">
+
+ <target name="sample.main">
<!-- Create output directory structure and copy sample files in it -->
<mkdir dir="${target.sample.dir}"/>
@@ -243,13 +243,47 @@
<antcall target="sample.replace"/>
</target>
+
+ <target name="sample.clover" if="clover.enable">
+ <copy todir="${target.sample.lib.dir}" file="${clover.jar}"/>
+ </target>
+
+ <target name="sample" depends="init,sample.main,sample.clover"
+ description="Generate the sample application">
+ </target>
<!--
========================================================================
Run the full suite of tests on all defined containers.
========================================================================
-->
- <target name="test" depends="sample"
+ <target name="test.prepare.clover" if="clover.enable">
+
+ <property name="clover.system.parameter"
+
value="-Dcactus.framework.jar=${basedir}/${cactus.framework.clover.jar}"/>
+
+ <replace file="${target.sample.dir}/build.xml"
+ token="@cactus.clover.pathelement@">
+ <replacevalue><![CDATA[
+ <pathelement location="${clover.jar}"/>
+ ]]></replacevalue>
+ </replace>
+
+ </target>
+
+ <target name="test.prepare.noclover" unless="clover.enable">
+
+ <property name="clover.system.parameter" value=""/>
+
+ <replace file="${target.sample.dir}/build.xml"
+ token="@cactus.clover.pathelement@">
+ <replacevalue><![CDATA[]]></replacevalue>
+ </replace>
+
+ </target>
+
+ <target name="test"
+ depends="sample,test.prepare.clover,test.prepare.noclover"
description="Run the tests on all defined servers">
<argsList property="test.args.list">
@@ -264,7 +298,7 @@
<property name="cactus.home.weblogic6x"/>
<property name="cactus.home.weblogic7x"/>
<property name="cactus.home.jboss3x"/>
- <property name="cactus.port"/>
+ <property name="cactus.port"/>
</argsList>
<java classname="org.apache.tools.ant.Main" fork="yes"
@@ -283,6 +317,10 @@
<arg line="-buildfile ${target.sample.dir}/build.xml"/>
<arg value="test"/>
+ <!-- Override default cactus jar defined in the called script
+ by the clovered one if clover is enabled -->
+ <arg line="${clover.system.parameter}"/>
+
<classpath>
<pathelement path="${java.class.path}"/>
</classpath>
1.45 +9 -0 jakarta-cactus/gump.xml
Index: gump.xml
===================================================================
RCS file: /home/cvs/jakarta-cactus/gump.xml,v
retrieving revision 1.44
retrieving revision 1.45
diff -u -r1.44 -r1.45
--- gump.xml 5 Feb 2003 15:13:58 -0000 1.44
+++ gump.xml 6 Feb 2003 08:55:39 -0000 1.45
@@ -336,11 +336,20 @@
<ant buildfile="documentation/build.xml" target="release">
<property name="project.version" value="@@DATE@@"/>
+ <property name="javadoc.include" value="true"/>
</ant>
<depend project="jakarta-ant" inherit="runtime"/>
<depend project="xml-xerces"/>
<depend project="xml-xalan2"/>
+
+ <!-- Dependencies to make sure this project is not built if one of the
+ dependent project fails -->
+ <depend project="jakarta-cactus-framework-12"/>
+ <depend project="jakarta-cactus-framework-13"/>
+ <depend project="jakarta-cactus-anttasks"/>
+ <depend project="jakarta-cactus-sample-servlet-13"/>
+ <depend project="jakarta-cactus-sample-servlet-12"/>
<work nested="documentation/target/classes/java"/>
1.3 +8 -0 jakarta-cactus/build-common.xml
Index: build-common.xml
===================================================================
RCS file: /home/cvs/jakarta-cactus/build-common.xml,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- build-common.xml 3 Feb 2003 10:52:43 -0000 1.2
+++ build-common.xml 6 Feb 2003 08:55:39 -0000 1.3
@@ -41,7 +41,15 @@
========================================================================
-->
<target name="init.properties.target.j2ee" if="j2ee.api">
+
<property name="target.dir" value="${base.dir}/target-${j2ee.api}"/>
+
+ <!-- Clover write data at compile time *and* at runtime in this file.
+ Note: This property is required by Clover and represents the
+ location of the Clover database. -->
+ <property name="clover.initstring"
+ value="${basedir}/target-${j2ee.api}/clover-coverage.db"/>
+
</target>
<target name="init.properties.target.noj2ee" unless="j2ee.api">
<property name="target.dir" value="${base.dir}/target"/>
1.39 +0 -4 jakarta-cactus/framework/build.xml
Index: build.xml
===================================================================
RCS file: /home/cvs/jakarta-cactus/framework/build.xml,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -r1.38 -r1.39
--- build.xml 3 Feb 2003 08:36:18 -0000 1.38
+++ build.xml 6 Feb 2003 08:55:39 -0000 1.39
@@ -128,10 +128,6 @@
-->
<target name="init.clover" depends="init.common" if="clover.enable">
- <!-- Clover write data at compile time *and* at runtime in this file -->
- <property name="clover.initstring"
- value="${basedir}/target-${j2ee.api}/clover-coverage.db"/>
-
<dirname property="clover.db.dir" file="${clover.initstring}"/>
<mkdir dir="${clover.db.dir}"/>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]