Author: jsong
Date: Fri Apr  8 16:53:24 2005
New Revision: 160639

URL: http://svn.apache.org/viewcvs?view=rev&rev=160639
Log:
Update build scripts for controls dist tests, build controlsWeb against dist 
package.

Modified:
    incubator/beehive/trunk/controls/test/dist-test/build.xml
    incubator/beehive/trunk/controls/test/dist-test/common/path.properties
    incubator/beehive/trunk/controls/test/dist-test/common/run-test-build.xml

Modified: incubator/beehive/trunk/controls/test/dist-test/build.xml
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/dist-test/build.xml?view=diff&r1=160638&r2=160639
==============================================================================
--- incubator/beehive/trunk/controls/test/dist-test/build.xml (original)
+++ incubator/beehive/trunk/controls/test/dist-test/build.xml Fri Apr  8 
16:53:24 2005
@@ -30,7 +30,7 @@
     <target name="build.tests" description="Build all controls tests">
         <ant dir="../" antfile="build.xml" target="dbControl" 
inheritAll="false"/>
         <ant dir="../" antfile="build.xml" target="build" inheritAll="false"/>
-        <ant dir="../" antfile="build.xml" target="build-test-webapp" 
inheritAll="false"/>
+        <!--ant dir="../" antfile="build.xml" target="build-test-webapp" 
inheritAll="false"/-->
     </target>
        <target name="dirs">
                <mkdir dir="${test.dist.base.dir}/beehive-test-dist"/>
@@ -102,25 +102,39 @@
        <copy file="../../../samples/controls-db/build/dbControl.jar" 
              
tofile="${test.dist.base.dir}/beehive-test-dist/controls/test/jars/dbControl.jar"/>
        <copy file="../build/controlstestbeans.jar" 
-             
tofile="${test.dist.base.dir}/beehive-test-dist/controls/test/jars/controls.jar"/>
+             
tofile="${test.dist.base.dir}/beehive-test-dist/controls/test/jars/controlstestbeans.jar"/>
        <copy file="../build/controlstestdrivers.jar" 
-             
tofile="${test.dist.base.dir}/beehive-test-dist/controls/test/jars/drivers.jar"/>
+             
tofile="${test.dist.base.dir}/beehive-test-dist/controls/test/jars/controlstestdrivers.jar"/>
        <copy file="../build/controlstestjunits.jar" 
-             
tofile="${test.dist.base.dir}/beehive-test-dist/controls/test/jars/junits.jar"/>
+             
tofile="${test.dist.base.dir}/beehive-test-dist/controls/test/jars/controlstestjunits.jar"/>
 
        <!-- Copy test suites -->
        <copy 
todir="${test.dist.base.dir}/beehive-test-dist/controls/test/cases">
                        <fileset dir="../build/mantis.tch.cases" />
        </copy>
 
-
        <!--we need to make sure availability of 
location="${db.control.jar}"/-->
 
        <!-- Copy the web application to 
beehive-test-dist/controls/test/webapps-->
        <copy 
todir="${test.dist.base.dir}/beehive-test-dist/controls/test/webapps/controlsWeb">
-                       <fileset dir="../build/webapps/controlsWeb" />
+                       <fileset dir="../webapps/controlsWeb" />
+       </copy>
+
+       <!-- Inject milton into controlsWeb-->
+       <copy 
todir="${test.dist.base.dir}/beehive-test-dist/controls/test/webapps/controlsWeb/WEB-INF"
+                               overwrite="true">
+            <fileset dir="../webapps/common/milton">
+                <include name="src/**"/>
+            </fileset>
        </copy>
 
+       <copy 
todir="${test.dist.base.dir}/beehive-test-dist/controls/test/webapps/controlsWeb"
+                               verbose="true" overwrite="true">
+            <fileset dir="../webapps/common/milton">
+                <include name="resources/**"/>
+            </fileset>
+       </copy>       
+
        <!--Copu build script over/-->
        <copy file="common/run-test-build.xml" 
              
tofile="${test.dist.base.dir}/beehive-test-dist/controls/test/build.xml"/>
@@ -130,7 +144,6 @@
              
tofile="${test.dist.base.dir}/beehive-test-dist/controls/test/common/controls-test-imports.xml"/>
        <copy file="common/controls-test-web.xml" 
              
tofile="${test.dist.base.dir}/beehive-test-dist/controls/test/webapps/build.xml"/>
             
-
 
     </target>
 

Modified: incubator/beehive/trunk/controls/test/dist-test/common/path.properties
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/dist-test/common/path.properties?view=diff&r1=160638&r2=160639
==============================================================================
--- incubator/beehive/trunk/controls/test/dist-test/common/path.properties 
(original)
+++ incubator/beehive/trunk/controls/test/dist-test/common/path.properties Fri 
Apr  8 16:53:24 2005
@@ -2,14 +2,19 @@
 
 controls.test.home=${test.home}/controls
 
+# properties for controlsWeb that test controls on Tomcat
+webapp.name=controlsWeb
+webapp.dir=${build.dir}/webapps/${webapp.name}
+webapp.waitfor.url=${server.root.url}/${webapp.name}
+
 #properties required by tch to generate test report
 controls.test.root=${controls.test.home}
 controls.test.infra.dir=${controls.test.home}/test/infra
 
 #Where are the test binaries
-controls.test.junits.jar=${controls.test.home}/test/jars/junits.jar
-controls.test.drivers.jar=${controls.test.home}/test/jars/drivers.jar
-controls.test.controls.jar=${controls.test.home}/test/jars/controls.jar
+controls.test.junits.jar=${controls.test.home}/test/jars/controlstestjunits.jar
+controls.test.drivers.jar=${controls.test.home}/test/jars/controlstestdrivers.jar
+controls.test.controls.jar=${controls.test.home}/test/jars/controlstestbeans.jar
 
 #tch is a test util
 tch.home=${controls.test.home}/test/infra/tch

Modified: 
incubator/beehive/trunk/controls/test/dist-test/common/run-test-build.xml
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/dist-test/common/run-test-build.xml?view=diff&r1=160638&r2=160639
==============================================================================
--- incubator/beehive/trunk/controls/test/dist-test/common/run-test-build.xml 
(original)
+++ incubator/beehive/trunk/controls/test/dist-test/common/run-test-build.xml 
Fri Apr  8 16:53:24 2005
@@ -69,15 +69,53 @@
 
     <!-- ================================================================ -->
     <!--                                                                  -->
+    <!-- Target to build controlsWeb                                      -->
+    <!--                                                                  -->
+    <!-- ================================================================ -->
+    <target name="build.controlsWeb" description="Build controlsWeb to test 
controls">
+        <antcall target="update.runtime"/>
+        <copy 
tofile="${build.dir}/webapps/controlsWeb/WEB-INF/lib/controlstestbeans.jar"
+                               file="${basedir}/jars/controlstestbeans.jar"/>
+        <copy 
tofile="${build.dir}/webapps/controlsWeb/WEB-INF/lib/controlstestdrivers.jar"
+                               file="${basedir}/jars/controlstestdrivers.jar"/>
+        <copy 
tofile="${build.dir}/webapps/controlsWeb/WEB-INF/lib/dbControl.jar"
+                               file="${basedir}/jars/dbControl.jar"/>
+        <copy tofile="${build.dir}/webapps/controlsWeb/WEB-INF/lib/milton.jar"
+                               file="${basedir}/infra/milton/milton.jar"/>
+        <build-webapp webappDir="${webapp.dir}"/>
+    </target>
+
+    <target name="clean.controlsweb" description="Clean controlsWeb">
+        <clean-webapp webappDir="${webapp.dir}"/>
+        <delete dir="${webapp.dir}/WEB-INF/lib"/>
+        <delete>
+           <fileset dir="${webapp.dir}/WEB-INF" 
includes="beehive-netui-tags*.*"/>
+        </delete>
+    </target>
+
+    <target name="update.runtime" description="Update NetUI runtime in 
controlsWeb without compiling">
+         <deploy-netui webappDir="${webapp.dir}"/>
+    </target>
+
+    <!-- ================================================================ -->
+    <!--                                                                  -->
     <!-- Target to run all checkin/detailed tests                              
    -->
     <!--                                                                  -->
     <!-- ================================================================ -->
     <target name="run.tests" depends="make.controls.report.dir" 
description="Run all tests">
+       <antcall target="prepare.controlsWeb"/>
+       <antcall target="build.controlsWeb"/>
                <antcall target="checkin.tests"/>
                <!--It is OK to have failures in detailed.tests. commented out 
temporarily-->
        <!--antcall target="detailed.tests"/-->
     </target>
 
+    <target name="prepare.controlsWeb" description="Prepare controlsWeb in 
build area">
+        <copy todir="${build.dir}/webapps/controlsWeb">
+              <fileset dir="${controls.test.home}/test/webapps/controlsWeb"/>
+        </copy>
+    </target>
+
        <target name="make.controls.report.dir" unless="controls.dir.exist">
                <echo message="make.controls.report.dir get called"/>
                <mkdir dir="${build.dir}/testResults/controls"/>                
                
@@ -124,13 +162,13 @@
                <sequential>
                        <echo message="start a second thread, wait for Tomcat 
to start."/>
                        <sleep seconds="20"/>
-                       <echo message="continue the second thread, deploy 
controlsTestWeb."/>
+                       <echo message="continue the second thread, deploy 
controlsWeb."/>
                        <ant dir ="./webapps" antfile="build.xml" 
target="ensure.deployed">
-                               <property name="build.dir" value="${basedir}"/>
+                               <property name="build.dir" 
value="${build.dir}"/>
                        </ant>
                        <echo message="continue the second thread, run junit 
tests."/>
                        <antcall target="run"/>
-                       <echo message="continue the second thread, undeploy 
controlsTestWeb."/>
+                       <echo message="continue the second thread, undeploy 
controlsWeb."/>
                        <ant dir ="./webapps" antfile="build.xml" 
target="undeploy"/>
                        <echo message="stop tomcat server, finish all the 
threads."/>
             <antcall target="tomcat.stop"/>


Reply via email to