You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hivemind.apache.org by hl...@apache.org on 2005/09/22 15:03:35 UTC

svn commit: r290935 - in /jakarta/hivemind/trunk: examples/build.xml framework/build.xml hivebuild/module.xml jmx/build.xml library/build.xml project.properties status.xml

Author: hlship
Date: Thu Sep 22 06:03:29 2005
New Revision: 290935

URL: http://svn.apache.org/viewcvs?rev=290935&view=rev
Log:
Change the build scripts to allow for test case classes ending in "Test", and to output source with the JavaDoc

Modified:
    jakarta/hivemind/trunk/examples/build.xml
    jakarta/hivemind/trunk/framework/build.xml
    jakarta/hivemind/trunk/hivebuild/module.xml
    jakarta/hivemind/trunk/jmx/build.xml
    jakarta/hivemind/trunk/library/build.xml
    jakarta/hivemind/trunk/project.properties
    jakarta/hivemind/trunk/status.xml

Modified: jakarta/hivemind/trunk/examples/build.xml
URL: http://svn.apache.org/viewcvs/jakarta/hivemind/trunk/examples/build.xml?rev=290935&r1=290934&r2=290935&view=diff
==============================================================================
--- jakarta/hivemind/trunk/examples/build.xml (original)
+++ jakarta/hivemind/trunk/examples/build.xml Thu Sep 22 06:03:29 2005
@@ -16,7 +16,6 @@
 -->
 <project name="HiveMind Examples" default="jar">
   <property name="module.name" value="hivemind-examples"/>
-  <property name="javadoc.package" value="org.apache.examples.*"/>
 	
   <!-- Override the default, and leave the examples.jar in the local target directory. -->
 	

Modified: jakarta/hivemind/trunk/framework/build.xml
URL: http://svn.apache.org/viewcvs/jakarta/hivemind/trunk/framework/build.xml?rev=290935&r1=290934&r2=290935&view=diff
==============================================================================
--- jakarta/hivemind/trunk/framework/build.xml (original)
+++ jakarta/hivemind/trunk/framework/build.xml Thu Sep 22 06:03:29 2005
@@ -16,7 +16,6 @@
 -->
 <project name="HiveMind Framework" default="jar" basedir=".">
 	<property name="module.name" value="hivemind"/>
-	<property name="javadoc.package" value="org.apache.hivemind.*"/>
   
     <property name="module.junit.use" value="compile"/>
   

Modified: jakarta/hivemind/trunk/hivebuild/module.xml
URL: http://svn.apache.org/viewcvs/jakarta/hivemind/trunk/hivebuild/module.xml?rev=290935&r1=290934&r2=290935&view=diff
==============================================================================
--- jakarta/hivemind/trunk/hivebuild/module.xml (original)
+++ jakarta/hivemind/trunk/hivebuild/module.xml Thu Sep 22 06:03:29 2005
@@ -14,263 +14,169 @@
    See the License for the specific language governing permissions and
    limitations under the License.
 -->
-
 <project name="module">
 	<!-- 
 		Imports are computed relative the this file (to the build.xml
 		that imported this file). -->
-	
 	<import file="hivebuild.xml"/>
 	<import file="dependency.xml"/>
 	<import file="forrestdoc.xml"/>
-  <property file="${hivebuild.dir}/module.properties"/>		
+	<property file="${hivebuild.dir}/module.properties"/>
 	<property name="forrest.report-menu.file" value="${project.forrest.xdocs.dir}/${module.name}/report-menu.ent"/>
-		
 	<!-- The default classpath for compilation is all external package JARs. -->
-	
 	<path id="default.test-compile.classpath">
 		<path refid="default.compile.classpath"/>
 		<path location="${java.classes.dir}"/>
 		<fileset dir="${module.lib.dir}" includes="test/**/*.jar"/>
 	</path>
-	
 	<path id="default.test.classpath">
 		<path refid="default.test-compile.classpath"/>
 		<pathelement location="${test.classes.dir}"/>
-    <fileset dir="${module.lib.dir}" includes="run/**/*.jar"/>
-		
+		<fileset dir="${module.lib.dir}" includes="run/**/*.jar"/>
 		<!-- To pick up any classpath resources. -->
-		
 		<path location="${test.src.dir}"/>
-		
 		<!-- To pick up log4j.properties or other runtime resources. -->
-		<pathelement location="${conf.src.dir}"/>	
-		
+		<pathelement location="${conf.src.dir}"/>
 		<!-- This is pretty specific to HiveMind, but eventually
 				 everything will be a HiveMind module. Pick up
 				 the module deployment descriptor. -->
-				 
-		<pathelement location="${descriptor.src.dir}"/>	
-    
-    <!-- Pick up the JUnit and XML runtime provided with Ant. -->
-    
-    <fileset dir="${ant.home}/lib">
-      <include name="junit-${module.junit.version}.jar"/>
-      <include name="xml-apis.jar"/>
-      <include name="xercesImpl.jar"/>
-    </fileset>
+		<pathelement location="${descriptor.src.dir}"/>
+		<!-- Pick up the JUnit and XML runtime provided with Ant. -->
+		<fileset dir="${ant.home}/lib">
+			<include name="junit-${module.junit.version}.jar"/>
+			<include name="xml-apis.jar"/>
+			<include name="xercesImpl.jar"/>
+		</fileset>
 	</path>
-	
 	<path id="default.source.path">
 		<pathelement location="${java.src.dir}"/>
-		<pathelement location="${generated-java.src.dir}"/>	
+		<pathelement location="${generated-java.src.dir}"/>
 	</path>
-	
 	<macrodef name="copy-source-resources">
 		<attribute name="classes-dir" default="${java.classes.dir}" description="Directory to copy resources to."/>
-		
 		<sequential>
-		
 			<announce message="Copying resources to @{classes-dir} ..."/>
-			
 			<copy todir="@{classes-dir}" includeEmptyDirs="false">
 				<fileset dir="${java.src.dir}">
-					<exclude name="**/*.java"/>	
+					<exclude name="**/*.java"/>
 					<exclude name="**/package.html"/>
 				</fileset>
 			</copy>
-			
 		</sequential>
-		
 	</macrodef>
-	
 	<macrodef name="default-compile">
-		<attribute name="compile-classpath-id" 
-				default="default.compile.classpath"
-				description="Reference to a path defining compile-time libraries."/>
-		<attribute name="sourcepath-id"
-			default="default.source.path"
+		<attribute name="compile-classpath-id" default="default.compile.classpath"
+			description="Reference to a path defining compile-time libraries."/>
+		<attribute name="sourcepath-id" default="default.source.path"
 			description="Referencce to a path of source directories to compile."/>
-		<attribute name="classes-dir"
-				default="${java.classes.dir}"
-				description="Directory to compile classes into."/>
-		
+		<attribute name="classes-dir" default="${java.classes.dir}" description="Directory to compile classes into."/>
 		<sequential>
-			
 			<antcall target="-compile-init"/>
 			<mkdir dir="@{classes-dir}"/>
-			
 			<!-- Make the directory, before it is referenced via default.compile.classpath.
 				   The javacc.xml module actually puts files into generated Java.  Perhaps
 				   in the future, an XDoclet extension will make use of this as well. -->
-			
 			<announce message="Compiling Java sources to @{classes-dir} ..."/>
-			
-			<javac
-				destdir="@{classes-dir}"
-				classpathref="@{compile-classpath-id}"
-        debug="${module.javac.debug}"
-        debuglevel="${module.javac.debuglevel}"
-        optimize="${module.javac.optimize}"
-        deprecation="${module.javac.deprecation}"
-        target="${module.javac.target}"
-        verbose="${module.javac.verbose}"
-        source="${module.javac.source}"
-        listfiles="${module.javac.listfiles}"
-        >
+			<javac destdir="@{classes-dir}" classpathref="@{compile-classpath-id}" debug="${module.javac.debug}"
+				debuglevel="${module.javac.debuglevel}" optimize="${module.javac.optimize}"
+				deprecation="${module.javac.deprecation}" target="${module.javac.target}"
+				verbose="${module.javac.verbose}" source="${module.javac.source}" listfiles="${module.javac.listfiles}">
 				<src>
 					<path refid="@{sourcepath-id}"/>
-				</src>	
+				</src>
 			</javac>
-				
-			<copy-source-resources classes-dir="@{classes-dir}"/>				
-		</sequential>	
+			<copy-source-resources classes-dir="@{classes-dir}"/>
+		</sequential>
 	</macrodef>
-	
 	<macrodef name="default-compile-tests">
-		<attribute name="compile-classpath-id"
-			default="default.test-compile.classpath"
+		<attribute name="compile-classpath-id" default="default.test-compile.classpath"
 			description="Reference to a path used to compile unit tests."/>
-    <sequential>
-      
-      <ibiblio-dependency artifact="junit" version="3.8.1" group="junit" use="${module.junit.use}"/>
-      
-      <mkdir dir="${test.classes.dir}"/>
-      
-      <announce message="Compiling tests to ${test.classes.dir} ..."/>
-      
-      <javac destdir="${test.classes.dir}" 
-        classpathref="@{compile-classpath-id}"
-        srcdir="${test.src.dir}" 
-        debug="${module.javac-test.debug}" 
-        debuglevel="${module.javac-test.debuglevel}" 
-        optimize="${module.javac-test.optimize}" 
-        deprecation="${module.javac-test.deprecation}" 
-        target="${module.javac-test.target}" 
-        verbose="${module.javac-test.verbose}" 
-        source="${module.javac-test.source}" 
-        listfiles="${module.javac-test.listfiles}" />
-    </sequential>
+		<sequential>
+			<ibiblio-dependency artifact="junit" version="3.8.1" group="junit" use="${module.junit.use}"/>
+			<mkdir dir="${test.classes.dir}"/>
+			<announce message="Compiling tests to ${test.classes.dir} ..."/>
+			<javac destdir="${test.classes.dir}" classpathref="@{compile-classpath-id}" srcdir="${test.src.dir}"
+				debug="${module.javac-test.debug}" debuglevel="${module.javac-test.debuglevel}"
+				optimize="${module.javac-test.optimize}" deprecation="${module.javac-test.deprecation}"
+				target="${module.javac-test.target}" verbose="${module.javac-test.verbose}"
+				source="${module.javac-test.source}" listfiles="${module.javac-test.listfiles}"/>
+		</sequential>
 	</macrodef>
-	
-  <available property="junit-available" file="${ant.home}/lib/${module.junit.jar}"/>
-  
-  <target name="-install-junit" unless="junit-available">
-      <copy file="${external.lib.dir}/${module.junit.jar}"
-            todir="${ant.home}/lib"/>
-             
-      <announce message="${module.junit.jar} has been installed to ${ant.home}/lib."/>
-      <announce message="You must restart the build to continue."/>
-      
-      <fail message="You must restart the build to continue."/>            
-  </target>
-  
+	<available property="junit-available" file="${ant.home}/lib/${module.junit.jar}"/>
+	<target name="-install-junit" unless="junit-available">
+		<copy file="${external.lib.dir}/${module.junit.jar}" todir="${ant.home}/lib"/>
+		<announce message="${module.junit.jar} has been installed to ${ant.home}/lib."/>
+		<announce message="You must restart the build to continue."/>
+		<fail message="You must restart the build to continue."/>
+	</target>
 	<macrodef name="default-run-tests">
-		<attribute name="classpath-id" default="default.test.classpath"
-			description="Reference to path used for tests."/>
+		<attribute name="classpath-id" default="default.test.classpath" description="Reference to path used for tests."/>
 		<attribute name="fork" default="${module.junit.fork}" description="Run the tests in a seperate JVM if on."/>
 		<element name="junit-elements" optional="true" description="Additional elements placed within the junit task."/>
-		
 		<sequential>
-   
-      <antcall target="-install-junit"/>
-      
+			<antcall target="-install-junit"/>
 			<mkdir dir="${junit.temp.dir}"/>
 			<mkdir dir="${junit.report.dir}"/>
-
 			<announce message="Running unit tests ..."/>
-
-			<junit 
-				fork="@{fork}"
-        forkmode="${module.junit.forkmode}"
-				haltonfailure="off"
-				failureproperty="junit-failure"
-				tempdir="${junit.temp.dir}">
-					
-					<classpath refid="@{classpath-id}"/>
-          
-          <sysproperty key="PROJECT_ROOT" value="${project.dir}"/>
-          <sysproperty key="BASEDIR" value="${basedir}"/>   
-          
-          <jvmarg line="${module.junit.jvmarg}"/>
-					
-					<formatter type="xml"/>
-          <formatter type="brief" usefile="false"/>
-          <formatter type="plain"/>
-          					
-					<batchtest todir="${junit.report.dir}">
-						<fileset dir="${test.classes.dir}">
-							<!-- Inner classes cause problems! -->
-							<exclude name="**/*$*.class"/>
-							<include name="**/Test*.class"/>	
-						</fileset>	
-					</batchtest>	
-					
-					<junit-elements/>					
+			<junit fork="@{fork}" forkmode="${module.junit.forkmode}" haltonfailure="off"
+				failureproperty="junit-failure" tempdir="${junit.temp.dir}">
+				<classpath refid="@{classpath-id}"/>
+				<sysproperty key="PROJECT_ROOT" value="${project.dir}"/>
+				<sysproperty key="BASEDIR" value="${basedir}"/>
+				<jvmarg line="${module.junit.jvmarg}"/>
+				<formatter type="xml"/>
+				<formatter type="brief" usefile="false"/>
+				<formatter type="plain"/>
+				<batchtest todir="${junit.report.dir}">
+					<fileset dir="${test.classes.dir}">
+						<!-- Inner classes cause problems! -->
+						<exclude name="**/*$*.class"/>
+						<!-- Old style naming: TestFoo -->
+						<include name="**/Test*.class"/>
+						<!-- I have seen the light!  FooTest makes more sense -->
+						<include name="**/*Test.class"/>
+					</fileset>
+				</batchtest>
+				<junit-elements/>
 			</junit>
-			
 			<fail if="junit-failure" message="Some tests failed."/>
-			
-		</sequential>	
+		</sequential>
 	</macrodef>
-	
 	<target name="compile-dependencies" description="Overriden to download dependencies as external package.">
 		<!-- Does nothing. This is often overriden, and becomes a series of
 			   calls to macros defined in dependency.xml. -->
 	</target>
-	 
 	<target name="-compile-init">
-		<mkdir dir="${generated-java.src.dir}"/>				
+		<mkdir dir="${generated-java.src.dir}"/>
 	</target>
-	
 	<!-- Usually overriden so that the options used when compiling, especially compile-classpath-id, can be overriden. -->
-	
 	<target name="compile" description="Compile Java source code." depends="compile-dependencies">
 		<default-compile/>
 	</target>
-	
 	<target name="compile-tests" description="Compiles JUnit tests." depends="compile">
 		<default-compile-tests/>
 	</target>
-	
 	<target name="run-tests" description="Runs JUnit tests." depends="compile-tests" unless="hivebuild.skip-tests">
-		<default-run-tests/>	
+		<default-run-tests/>
 	</target>
-	
 	<macrodef name="default-javadoc">
 		<attribute name="sourcepath-id" default="default.source.path" description="Reference to source path."/>
 		<attribute name="classpath-id" default="default.compile.classpath"/>
-		
 		<sequential>
-			<fail unless="javadoc.package" message="You must specify property javadoc.packages."/>
-			
 			<mkdir dir="${javadoc.target.dir}"/>
-			
 			<announce message="Generating Javadoc ..."/>
-	
-			<javadoc
-				destdir="${javadoc.target.dir}"
-				classpathref="@{classpath-id}"
-				version="yes"
-				use="yes"
-				splitindex="yes"
+			<javadoc destdir="${javadoc.target.dir}" classpathref="@{classpath-id}" version="yes" use="yes"
+				splitindex="yes" source="${module.javac.source}" linksource="true"
 				windowtitle="${module.name} - ${project.version} API">
-				<package name="${javadoc.package}"/>
-				<sourcepath>
-					<pathelement location="${java.src.dir}"/>
-					<pathelement location="${generated-java.src.dir}"/>	
-				</sourcepath>
+				<packageset dir="${java.src.dir}"/>
 			</javadoc>
-		</sequential>	
+		</sequential>
 	</macrodef>
-	
 	<target name="javadoc" depends="-compile-init" description="Create JavaDoc from Java source files.">
-		<default-javadoc/>	
+		<default-javadoc/>
+	</target>
+	<target name="clean-code" description="Cleans compiled Java code.">
+		<delete dir="${java.classes.dir}" quiet="true"/>
+		<delete dir="${test.classes.dir}" quiet="true"/>
 	</target>
-			
-  <target name="clean-code"
-    description="Cleans compiled Java code.">
-    <delete dir="${java.classes.dir}" quiet="true"/>
-    <delete dir="${test.classes.dir}" quiet="true"/>
-  </target>      
-</project>
\ No newline at end of file
+</project>

Modified: jakarta/hivemind/trunk/jmx/build.xml
URL: http://svn.apache.org/viewcvs/jakarta/hivemind/trunk/jmx/build.xml?rev=290935&r1=290934&r2=290935&view=diff
==============================================================================
--- jakarta/hivemind/trunk/jmx/build.xml (original)
+++ jakarta/hivemind/trunk/jmx/build.xml Thu Sep 22 06:03:29 2005
@@ -17,7 +17,6 @@
 <project name="HiveMind JMX Library" default="jar">
 
 	<property name="module.name" value="hivemind-jmx" />
-	<property name="javadoc.package" value="org.apache.hivemind.management.*" />
 
 	<property name="root.dir" value=".." />
 	<property file="${root.dir}/build.properties" />

Modified: jakarta/hivemind/trunk/library/build.xml
URL: http://svn.apache.org/viewcvs/jakarta/hivemind/trunk/library/build.xml?rev=290935&r1=290934&r2=290935&view=diff
==============================================================================
--- jakarta/hivemind/trunk/library/build.xml (original)
+++ jakarta/hivemind/trunk/library/build.xml Thu Sep 22 06:03:29 2005
@@ -17,10 +17,9 @@
 <project name="HiveMind Standard Library" default="jar">
 
 	<property name="module.name" value="hivemind-lib"/>
-	<property name="javadoc.package" value="org.apache.hivemind.lib.*"/>
 	
 	<property name="root.dir" value=".."/>
-  <property file="${root.dir}/build.properties"/>
+    <property file="${root.dir}/build.properties"/>
 	<import file="${root.dir}/hivebuild/jar-module.xml"/>
 	<import file="${hivebuild.dir}/javadoc-report.xml"/>	
 	<import file="${hivebuild.dir}/clover-report.xml"/>

Modified: jakarta/hivemind/trunk/project.properties
URL: http://svn.apache.org/viewcvs/jakarta/hivemind/trunk/project.properties?rev=290935&r1=290934&r2=290935&view=diff
==============================================================================
--- jakarta/hivemind/trunk/project.properties (original)
+++ jakarta/hivemind/trunk/project.properties Thu Sep 22 06:03:29 2005
@@ -13,7 +13,7 @@
 # limitations under the License.
 
 project.name=jakarta-hivemind
-project.version=1.1-beta-4
+project.version=1.1-rc-1
 
 dist.name=hivemind
 

Modified: jakarta/hivemind/trunk/status.xml
URL: http://svn.apache.org/viewcvs/jakarta/hivemind/trunk/status.xml?rev=290935&r1=290934&r2=290935&view=diff
==============================================================================
--- jakarta/hivemind/trunk/status.xml (original)
+++ jakarta/hivemind/trunk/status.xml Thu Sep 22 06:03:29 2005
@@ -30,8 +30,9 @@
     </actions>
   </todo>
   <changes>
-    <release version="1.1-beta-4" date="unreleased">
-      <action type="add" dev="HLS">Add several more convienience methods, related to mock objects, to HiveMindTestCase</action>      
+    <release version="1.1-rc-1" date="unreleased">
+      <action type="add" dev="HLS">Add several more convienience methods, related to mock objects, to HiveMindTestCase</action>
+      <action type="update" dev="HLS">Change the build scripts to allow for test case classes ending in "Test", and to output source with the JavaDoc</action>      
     </release>
     <release version="1.1-beta-3" date="Aug 22 2005">
       <action type="update" dev="HLS">Change dist targets to use SSH passphrase for authentication.</action>



---------------------------------------------------------------------
To unsubscribe, e-mail: hivemind-cvs-unsubscribe@jakarta.apache.org
For additional commands, e-mail: hivemind-cvs-help@jakarta.apache.org