harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From smish...@apache.org
Subject svn commit: r641767 - in /harmony/enhanced/buildtest/trunk/infra: build.xml scripts/config.xml
Date Thu, 27 Mar 2008 10:26:14 GMT
Author: smishura
Date: Thu Mar 27 03:26:09 2008
New Revision: 641767

URL: http://svn.apache.org/viewvc?rev=641767&view=rev
Log:
Add check for generated required-parameters.properties

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

Modified: harmony/enhanced/buildtest/trunk/infra/build.xml
URL: http://svn.apache.org/viewvc/harmony/enhanced/buildtest/trunk/infra/build.xml?rev=641767&r1=641766&r2=641767&view=diff
==============================================================================
--- harmony/enhanced/buildtest/trunk/infra/build.xml (original)
+++ harmony/enhanced/buildtest/trunk/infra/build.xml Thu Mar 27 03:26:09 2008
@@ -228,7 +228,7 @@
                 buildpath="${scripts.dir}">
         </subant>
 
-        <!-- TODO check generated required-parameters.properties -->
+        <check-required-parameters />
     </target>
 
     <target name="create-local-configuration"
@@ -358,4 +358,34 @@
         <setproxy proxyhost="${http.proxyHost}" proxyport="${http.proxyPort}" />
     </target>
 
+    <macrodef name="check-required-parameters">
+        <sequential>
+
+            <!-- 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}
+The list of all required properties is in:
+                ${required.parameters.location}
+Please find unset properties or empty values and specify them in:
+                ${framework.local.configuration.file}
+And rerun install
+            </fail>
+        </sequential>
+    </macrodef>
 </project>

Modified: harmony/enhanced/buildtest/trunk/infra/scripts/config.xml
URL: http://svn.apache.org/viewvc/harmony/enhanced/buildtest/trunk/infra/scripts/config.xml?rev=641767&r1=641766&r2=641767&view=diff
==============================================================================
--- harmony/enhanced/buildtest/trunk/infra/scripts/config.xml (original)
+++ harmony/enhanced/buildtest/trunk/infra/scripts/config.xml Thu Mar 27 03:26:09 2008
@@ -68,6 +68,7 @@
                 <propertyref name="all.props" />
                 <propertyref name="scripts.dir" />
                 <propertyref name="config.dir" />
+                <propertyref name="required.parameters.location" />
                 <!--propertyref name="framework.local.configuration.file" /-->
                 <propertyset refid="global.build.parameters.id" />
             </propertyset>
@@ -171,10 +172,12 @@
 
     <target name="-gen-required-parameters">
 
-        <echo file="${config.dir}/required-parameters.properties">#
-# Required Parameters Settings File
-# TODO: add more words here
-
+        <echo file="${required.parameters.location}">#
+# Auto generated required parameters settings file
+# 
+# DON'T EDIT THIS FILE: specify all values for properties in
+#                       framework local properties file
+#
 </echo>
 
         <property name="all.props" location="${config.dir}/all.props" />
@@ -202,6 +205,7 @@
             <propertyset>
                 <propertyref name="scripts.dir" />
                 <propertyref name="config.dir" />
+                <propertyref name="required.parameters.location" />
             </propertyset>
         </ant>
 
@@ -220,6 +224,7 @@
                 <propertyref name="donext" />
                 <propertyref name="scripts.dir" />
                 <propertyref name="config.dir" />
+                <propertyref name="required.parameters.location" />
             </propertyset>
         </ant>
     </target>
@@ -253,6 +258,7 @@
             <propertyset>
                 <propertyref name="scripts.dir" />
                 <propertyref name="config.dir" />
+                <propertyref name="required.parameters.location" />
             </propertyset>
         </subant>
 
@@ -261,8 +267,7 @@
     <macrodef name="flash-property">
         <attribute name="propname" />
         <sequential>
-            <echo file="${config.dir}/required-parameters.properties"
-                  append="true">
+            <echo file="${required.parameters.location}" append="true">
 #${@{propname}.description}
 @{propname}=${@{propname}}
 </echo>



Mime
View raw message