continuum-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wsm...@apache.org
Subject svn commit: r745716 - in /continuum/trunk/continuum-webapp-test: Readme.txt it-pom.xml src/test/it-resources/it.properties src/test/tomcat5x/context.xml
Date Thu, 19 Feb 2009 03:18:46 GMT
Author: wsmoak
Date: Thu Feb 19 03:18:45 2009
New Revision: 745716

URL: http://svn.apache.org/viewvc?rev=745716&view=rev
Log:
[CONTINUUM-2073] Adjust configuration to use the full install of Tomcat (where Cargo unzips
it) as an 'existing' container.  Copy the extra jars and context.xml file into place.  This
currently runs on the default port 8080 and is working to start Tomcat and deploy the Continuum
webapp, though the tests are still failing.

Added:
    continuum/trunk/continuum-webapp-test/src/test/tomcat5x/context.xml
Modified:
    continuum/trunk/continuum-webapp-test/Readme.txt
    continuum/trunk/continuum-webapp-test/it-pom.xml
    continuum/trunk/continuum-webapp-test/src/test/it-resources/it.properties

Modified: continuum/trunk/continuum-webapp-test/Readme.txt
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp-test/Readme.txt?rev=745716&r1=745715&r2=745716&view=diff
==============================================================================
--- continuum/trunk/continuum-webapp-test/Readme.txt (original)
+++ continuum/trunk/continuum-webapp-test/Readme.txt Thu Feb 19 03:18:45 2009
@@ -13,7 +13,13 @@
 
 Run Selenium tests in src/test/it with Maven
  * modify src/test/resources/it.properties as needed
- * mvn clean install -f pom-it.xml
+ * mvn clean install -f it-pom.xml
+
+ Note that this does not install anything, it simply runs through the lifecycle including
the integration test phases.
+ More properly it would be 'mvn clean post-integration-test', but install is much shorter
to type. :)
+
+ After you have run through the lifecycle once to set up the container and webapps, you can
re-start it using:
+ mvn cargo:start
 
 Run Selenium teests in src/test/pom2 with Maven
  * set TOMCAT_HOME environment variable to location of Tomcat 5.5.x installation

Modified: continuum/trunk/continuum-webapp-test/it-pom.xml
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp-test/it-pom.xml?rev=745716&r1=745715&r2=745716&view=diff
==============================================================================
--- continuum/trunk/continuum-webapp-test/it-pom.xml (original)
+++ continuum/trunk/continuum-webapp-test/it-pom.xml Thu Feb 19 03:18:45 2009
@@ -106,82 +106,77 @@
             <containerId>${container.name}</containerId>
             <zipUrlInstaller>
               <url>${container.url}</url>
-              <installDir>${project.build.directory}/installs/${container.name}</installDir>
+              <installDir>${project.build.directory}/installs</installDir>
             </zipUrlInstaller>
             <log>${project.build.directory}/logs/${container.name}.log</log>
             <output>${project.build.directory}/logs/${container.name}.out</output>
             <timeout>600000</timeout>
             <systemProperties>
               <appserver.base>${project.build.directory}</appserver.base>
+              <derby.system.home>${project.build.directory}</derby.system.home>
             </systemProperties>
-            <dependencies>
-              <dependency>
-              <groupId>org.apache.derby</groupId>
-              <artifactId>derby</artifactId>
-            </dependency>
-              <dependency>
-                <groupId>org.apache.derby</groupId>
-                <artifactId>derbytools</artifactId>
-              </dependency>
-              <dependency>
-                <groupId>javax.mail</groupId>
-                <artifactId>mail</artifactId>
-              </dependency>
-              <dependency>
-                <groupId>javax.activation</groupId>
-                <artifactId>activation</artifactId>
-              </dependency>
-        </dependencies>
           </container>
           <configuration>
-            <home>${project.build.directory}/${container.name}</home>
-            <type>standalone</type>
-            <properties>
-              <cargo.servlet.port>9595</cargo.servlet.port>
-            </properties>
-            <resources>
-              <resource>
-                <name>jdbc/users</name>
-                <type>javax.sql.DataSource</type>
-                <parameters>
-                  <driverClassName>org.apache.derby.jdbc.EmbeddedDriver</driverClassName>
-                  <url>jdbc:derby:${project.build.directory}/databases/${container.name}/users;create=true</url>
-                  <username>sa</username>
-                  <password></password>
-                </parameters>
-              </resource>
-              <resource>
-                <name>jdbc/continuum</name>
-                <type>javax.sql.DataSource</type>
-                <parameters>
-                  <driverClassName>org.apache.derby.jdbc.EmbeddedDriver</driverClassName>
-                  <url>jdbc:derby:${project.build.directory}/databases/${container.name}/data/builds;create=true</url>
-                  <username>sa</username>
-                  <password></password>
-                </parameters>
-              </resource>
-              <resource>
-                <name>mail/Session</name>
-                <type>javax.mail.Session</type>
-                <parameters>
-                  <mail.smtp.host>localhost</mail.smtp.host>
-                </parameters>
-              </resource>
-            </resources>
-            <deployables>
-              <deployable>
-                <groupId>${project.goupId}</groupId>
-                <artifactId>continuum-webapp</artifactId>
-                <type>war</type>
-                <properties>
-                  <context>continuum</context>
-                </properties>
-              </deployable>
-            </deployables>
+            <home>${project.build.directory}/${install.dir}/</home>
+            <type>existing</type>
           </configuration>
         </configuration>
       </plugin>
-
+      <plugin>
+        <groupId>org.codehaus.mojo</groupId>
+        <artifactId>dependency-maven-plugin</artifactId>
+        <executions>
+          <execution>
+            <id>unzip-continuum-webapp</id>
+            <phase>generate-resources</phase>
+            <goals>
+              <goal>unpack</goal>
+            </goals>
+            <configuration>
+              <artifactItems>
+                <artifactItem>
+                  <groupId>${project.groupId}</groupId>
+                  <artifactId>continuum-webapp</artifactId>
+                  <version>${project.version}</version>
+                  <type>war</type>
+                </artifactItem>
+              </artifactItems>
+              <outputDirectory>${project.build.directory}/${install.dir}/webapps/continuum</outputDirectory>
+            </configuration>
+          </execution>
+          <execution>
+            <id>copy-container-dependencies</id>
+            <phase>generate-resources</phase>
+            <goals>
+              <goal>copy-dependencies</goal>
+            </goals>
+            <configuration>
+              <overWriteReleases>false</overWriteReleases>
+              <overWriteSnapshots>true</overWriteSnapshots>
+              <excludeTransitive>false</excludeTransitive>
+              <outputDirectory>${project.build.directory}/${install.dir}/common/lib</outputDirectory>
+            </configuration>
+          </execution>
+        </executions>
+      </plugin>
+      <plugin>
+        <artifactId>maven-antrun-plugin</artifactId>
+        <executions>
+          <execution>
+            <id>copy-container-conf</id>
+            <phase>package</phase>
+            <configuration>
+              <tasks>
+                <copy todir="${project.build.directory}/${install.dir}/webapps/continuum/META-INF/"
+                       file="src/test/${container.name}/context.xml"/>
+              </tasks>
+            </configuration>
+            <goals>
+              <goal>run</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
       <plugin>
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-surefire-plugin</artifactId>
@@ -229,26 +224,13 @@
       <scope>test</scope>
     </dependency>
 
-    <!-- deployables -->
-    <dependency>
-      <groupId>org.apache.continuum</groupId>
-      <artifactId>continuum-webapp</artifactId>
-      <version>${project.version}</version>
-      <type>war</type>
-    </dependency>
-
-     <!-- container dependencies -->
+    <!-- container dependencies -->
     <dependency>
       <groupId>org.apache.derby</groupId>
        <artifactId>derby</artifactId>
        <version>10.1.3.1</version>
     </dependency>
     <dependency>
-      <groupId>org.apache.derby</groupId>
-       <artifactId>derbytools</artifactId>
-       <version>10.1.3.1</version>
-    </dependency>
-    <dependency>
       <groupId>javax.mail</groupId>
       <artifactId>mail</artifactId>
       <version>1.4</version>
@@ -295,5 +277,9 @@
     </profile>
 
   </profiles>
+  
+  <properties>
+    <install.dir>installs/apache-tomcat-5.5.27/apache-tomcat-5.5.27</install.dir>
+  </properties>
 
 </project>

Modified: continuum/trunk/continuum-webapp-test/src/test/it-resources/it.properties
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp-test/src/test/it-resources/it.properties?rev=745716&r1=745715&r2=745716&view=diff
==============================================================================
--- continuum/trunk/continuum-webapp-test/src/test/it-resources/it.properties (original)
+++ continuum/trunk/continuum-webapp-test/src/test/it-resources/it.properties Thu Feb 19 03:18:45
2009
@@ -1,6 +1,6 @@
 #properties for integration tests
 
-BASE_URL=http://localhost:9595/continuum
+BASE_URL=http://localhost:8080/continuum
 MAX_WAIT_TIME_IN_MS=60000
 
 ADMIN_USERNAME=admin

Added: continuum/trunk/continuum-webapp-test/src/test/tomcat5x/context.xml
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp-test/src/test/tomcat5x/context.xml?rev=745716&view=auto
==============================================================================
--- continuum/trunk/continuum-webapp-test/src/test/tomcat5x/context.xml (added)
+++ continuum/trunk/continuum-webapp-test/src/test/tomcat5x/context.xml Thu Feb 19 03:18:45
2009
@@ -0,0 +1,24 @@
+<Context>
+
+  <Resource name="jdbc/users"
+            auth="Container"
+            type="javax.sql.DataSource"
+            username="sa"
+            password=""
+            driverClassName="org.apache.derby.jdbc.EmbeddedDriver"
+            url="jdbc:derby:database/users;create=true" />
+
+  <Resource name="jdbc/continuum"
+            auth="Container"
+            type="javax.sql.DataSource"
+            username="sa"
+            password=""
+            driverClassName="org.apache.derby.jdbc.EmbeddedDriver"
+            url="jdbc:derby:database/continuum;create=true" />
+
+  <Resource name="mail/Session"
+            auth="Container"
+            type="javax.mail.Session"
+            mail.smtp.host="localhost"/>
+
+</Context>
\ No newline at end of file



Mime
View raw message