harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From smish...@apache.org
Subject svn commit: r644181 - /harmony/enhanced/buildtest/trunk/infra/build.xml
Date Thu, 03 Apr 2008 06:23:15 GMT
Author: smishura
Date: Wed Apr  2 23:23:15 2008
New Revision: 644181

URL: http://svn.apache.org/viewvc?rev=644181&view=rev
Log:
* Convert macrodef 'check-required-parameters' to target
* Add '-get-installed-suites' target used by setup & run

Modified:
    harmony/enhanced/buildtest/trunk/infra/build.xml

Modified: harmony/enhanced/buildtest/trunk/infra/build.xml
URL: http://svn.apache.org/viewvc/harmony/enhanced/buildtest/trunk/infra/build.xml?rev=644181&r1=644180&r2=644181&view=diff
==============================================================================
--- harmony/enhanced/buildtest/trunk/infra/build.xml (original)
+++ harmony/enhanced/buildtest/trunk/infra/build.xml Wed Apr  2 23:23:15 2008
@@ -229,7 +229,7 @@
                 buildpath="${scripts.dir}">
         </subant>
 
-        <check-required-parameters />
+        <antcall target="check-required-parameters" />
     </target>
 
     <target name="create-local-configuration"
@@ -247,23 +247,10 @@
                          Framework Setup Functionality
          ================================================================== -->
 
-    <target name="setup" depends="load-suites-configuration">
-
-        <!-- verify that all required params are set -->
-        <check-required-parameters />
-
-        <!-- get the list of installed suites -->
-        <pathconvert pathsep="," property="suites.setup.list">
-            <path>
-                <fileset dir="${config.dir}">
-                    <include name="*.properties" />
-                </fileset>
-            </path>
-            <chainedmapper>
-                <flattenmapper />
-                <globmapper from="*.properties" to="*" />
-            </chainedmapper>
-        </pathconvert>
+    <target name="setup"
+            depends="check-required-parameters,
+                     -get-installed-suites,
+                     load-suites-configuration">
 
         <!-- temporary file to store intermediate results of iteration -->
         <property name="tmp.file" location="${scripts.dir}/tmp.txt" />
@@ -272,7 +259,7 @@
                 target="-setup-suite"
                 inheritall="true"
                 inheritrefs="true">
-            <dirset dir="${adaptors.dir}" includes="${suites.setup.list}" />
+            <dirset dir="${adaptors.dir}" includes="${installed.suites.list}" />
         </subant>
         <delete file="${tmp.file}" />
     </target>
@@ -280,23 +267,10 @@
     <!-- ================================================================== 
                           Test Execution Functionality
          ================================================================== -->
-    <target name="run" depends="load-suites-configuration">
-
-        <!-- verify that all required params are set -->
-        <check-required-parameters />
-
-        <!-- get the list of set up suites -->
-        <pathconvert pathsep="," property="suites.run.list">
-            <path>
-                <fileset dir="${config.dir}">
-                    <include name="*.properties" />
-                </fileset>
-            </path>
-            <chainedmapper>
-                <flattenmapper />
-                <globmapper from="*.properties" to="*" />
-            </chainedmapper>
-        </pathconvert>
+    <target name="run"
+            depends="check-required-parameters,
+                     -get-installed-suites,
+                     load-suites-configuration">
 
         <!-- temporary file to store intermediate results of iteration -->
         <property name="tmp.file" location="${scripts.dir}/tmp.txt" />
@@ -305,7 +279,7 @@
                 target="-run-suite"
                 inheritall="true"
                 inheritrefs="true">
-            <dirset dir="${adaptors.dir}" includes="${suites.run.list}" />
+            <dirset dir="${adaptors.dir}" includes="${installed.suites.list}" />
             <property name="failonerror" value="false" />
         </subant>
 
@@ -409,29 +383,33 @@
 
     <target name="distclean" description="distclean" />
 
+    <!-- ================================================================== 
+                          Common Targets
+         ================================================================== -->
+
     <target name="-setup-proxy" if="http.proxyHost">
         <setproxy proxyhost="${http.proxyHost}" proxyport="${http.proxyPort}" />
     </target>
 
-    <macrodef name="check-required-parameters">
-        <sequential>
+    <target name="check-required-parameters">
 
-            <!-- The property is set only if there missed values
-                 for required properties -->
-            <loadfile property="required.parameters"
-                      srcfile="${required.parameters.location}">
-                <filterchain>
-                    <linecontainsregexp>
-                        <!-- find undefined and empty prop. values -->
-                        <regexp pattern="=(\$|$)" />
-                    </linecontainsregexp>
-                </filterchain>
-            </loadfile>
-
-            <fail>
-                <condition>
-                    <isset property="required.parameters" />
-                </condition>
+        <!-- The property is set only if there missed values
+             for required properties
+        -->
+        <loadfile property="required.parameters"
+                  srcfile="${required.parameters.location}">
+            <filterchain>
+                <linecontainsregexp>
+                    <!-- find undefined and empty prop. values -->
+                    <regexp pattern="=(\$|$)" />
+                </linecontainsregexp>
+            </filterchain>
+        </loadfile>
+
+        <fail>
+            <condition>
+                <isset property="required.parameters" />
+            </condition>
 #
 There are unset required properties for selected suites:
                 ${test.suites.names.list}
@@ -441,6 +419,22 @@
                 ${framework.local.configuration.file}
 And rerun install
             </fail>
-        </sequential>
-    </macrodef>
+    </target>
+
+    <target name="-get-installed-suites">
+
+        <!-- get the list of installed suites -->
+        <pathconvert pathsep="," property="installed.suites.list">
+            <path>
+                <fileset dir="${config.dir}">
+                    <include name="*.properties" />
+                </fileset>
+            </path>
+            <chainedmapper>
+                <flattenmapper />
+                <globmapper from="*.properties" to="*" />
+            </chainedmapper>
+        </pathconvert>
+    </target>
+
 </project>



Mime
View raw message