fixed issues with resource loading for maven int tests
[taxeditor.git] / eu.etaxonomy.taxeditor.test / pom.xml
index b87c33a9327637ac0b3f7b32e500390fa8fa86a5..740a383741b2faaf1a719781878f2c9a3f9dd136 100644 (file)
@@ -4,21 +4,25 @@
   <parent>\r
     <groupId>eu.etaxonomy</groupId>\r
     <artifactId>taxeditor-parent</artifactId>\r
-    <version>3.5.2-SNAPSHOT</version>\r
+    <version>3.6.1-SNAPSHOT</version>\r
   </parent>\r
   <modelVersion>4.0.0</modelVersion>\r
   <artifactId>eu.etaxonomy.taxeditor.test</artifactId>\r
   <packaging>eclipse-test-plugin</packaging>\r
   <name>UI Test Bundle</name>\r
-  <description>Holds all UI tests for the Taxonomic Editor</description>\r
+  <description>Holds all Tests for the Taxonomic Editor</description>\r
   <build>\r
     <plugins>\r
-      <!-- <plugin> -->\r
-      <!-- <groupId>org.eclipse.tycho</groupId> -->\r
-      <!-- <artifactId>tycho-maven-plugin</artifactId> -->\r
-      <!-- <version>${tycho.version}</version> -->\r
-      <!-- <extensions>true</extensions> -->\r
-      <!-- </plugin> -->\r
+<!--       <plugin> -->\r
+<!--         <groupId>org.eclipse.tycho</groupId> -->\r
+<!--         <artifactId>tycho-compiler-plugin</artifactId> -->\r
+<!--         <version>${tycho.version}</version> -->\r
+<!--         <configuration> -->\r
+<!--           <excludes> -->\r
+<!--             <exclude>**/*.*</exclude> -->\r
+<!--           </excludes> -->\r
+<!--         </configuration> -->\r
+<!--       </plugin> -->\r
       <plugin>\r
         <groupId>org.eclipse.tycho</groupId>\r
         <artifactId>target-platform-configuration</artifactId>\r
               <removeAll />\r
             </filter>\r
           </filters>\r
-          <!-- <dependency-resolution> -->\r
-          <!-- <extraRequirements> -->\r
-          <!-- product IU under test -->\r
-          <!-- <requirement> -->\r
-          <!-- <type>p2-installable-unit</type> -->\r
-          <!-- <id>eu.etaxonomy.taxeditor.product</id> -->\r
-          <!-- <versionRange>3.5.2.qualifier</versionRange> -->\r
-          <!-- </requirement> -->\r
-          <!-- </extraRequirements> -->\r
-          <!-- </dependency-resolution> -->\r
         </configuration>\r
       </plugin>\r
       <plugin>\r
         <artifactId>tycho-surefire-plugin</artifactId>\r
         <version>${tycho.version}</version>\r
         <configuration>\r
-          <!-- <testRuntime>p2-installed</testRuntime> -->\r
+          <!-- currently we run only the non-ui unit tests so we don't the \r
+            harness -->\r
           <!-- <useUIHarness>true</useUIHarness> -->\r
-          <!-- <providerHint>junit4</providerHint> -->\r
           <dependencies>\r
+            <!-- This will pull the feature and its dependent plugins into \r
+              the classpath for the tests. Note that this requires ALL taxeditor projects \r
+              to be installed. -->\r
             <dependency>\r
               <type>eclipse-feature</type>\r
               <artifactId>eu.etaxonomy.taxeditor.feature</artifactId>\r
               <version>1.0.0</version>\r
             </dependency>\r
           </dependencies>\r
-\r
         </configuration>\r
       </plugin>\r
+      <plugin>\r
+        <groupId>org.eclipse.jetty</groupId>\r
+        <artifactId>jetty-maven-plugin</artifactId>\r
+        <version>9.2.9.v20150224</version>\r
+        <configuration>\r
+          <systemProperties>\r
+            <systemProperty>\r
+              <name>spring.profiles.active</name>\r
+              <value>remoting</value>\r
+            </systemProperty>\r
+            <systemProperty>\r
+              <name>cdm.beanDefinitionFile</name>\r
+              <value>${basedir}/src/test/resources/datasources.xml</value>\r
+            </systemProperty>\r
+            <systemProperty>\r
+              <name>cdm.datasource</name>\r
+              <value>cdmTest</value>\r
+            </systemProperty>\r
+          </systemProperties>\r
+          <stopPort>9191</stopPort>\r
+          <stopKey>jetty-cdm-server</stopKey>\r
+          <stopWait>10</stopWait>\r
+          <httpConnector>\r
+            <port>9090</port>\r
+          </httpConnector>\r
+          <war>${project.parent.basedir}/eu.etaxonomy.taxeditor.cdmlib/src/main/resources/etc/jetty/cdmlib-remote-webapp.war</war>\r
+          <daemon>true</daemon>\r
+        </configuration>\r
+        <executions>\r
+          <execution>\r
+            <id>start-jetty</id>\r
+            <phase>pre-integration-test</phase>\r
+            <goals>\r
+              <goal>deploy-war</goal>\r
+            </goals>\r
+            <configuration>\r
+              <scanIntervalSeconds>0</scanIntervalSeconds>\r
+            </configuration>\r
+          </execution>\r
+          <execution>\r
+            <id>stop-jetty</id>\r
+            <phase>post-integration-test</phase>\r
+            <goals>\r
+              <goal>stop</goal>\r
+            </goals>\r
+          </execution>\r
+        </executions>\r
+      </plugin>\r
     </plugins>\r
   </build>\r
 </project>
\ No newline at end of file