oxalis-integration-test
Used in:
components
- OverviewOverview
- VersionsVersions
- DependentsDependents
- DependenciesDependencies
<dependency>
<groupId>no.difi.oxalis</groupId>
<artifactId>oxalis-integration-test</artifactId>
<version>4.0.0-RC2</version>
</dependency><?xml version="1.0" encoding="UTF-8"?>
<!--
~ Copyright 2010-2017 Norwegian Agency for Public Management and eGovernment (Difi)
~
~ Licensed under the EUPL, Version 1.1 or – as soon they
~ will be approved by the European Commission - subsequent
~ versions of the EUPL (the "Licence");
~
~ You may not use this work except in compliance with the Licence.
~
~ You may obtain a copy of the Licence at:
~
~ https://joinup.ec.europa.eu/community/eupl/og_page/eupl
~
~ Unless required by applicable law or agreed to in
~ writing, software distributed under the Licence is
~ distributed on an "AS IS" basis,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
~ express or implied.
~ See the Licence for the specific language governing
~ permissions and limitations under the Licence.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>no.difi.oxalis</groupId>
<artifactId>oxalis</artifactId>
<version>4.0.0-RC2</version>
</parent>
<artifactId>oxalis-integration-test</artifactId>
<packaging>jar</packaging>
<name>Oxalis :: Integration test</name>
<description>
Oxalis integration test.
Compiles and packages everything, after which the web container
is started in the pre-integration-test phase, the .war file is deployed
and the tests are executed in the integration-test phase.
After the tests have been executed, the web container is stopped in
the post-integration-test phase.
The reason for using failsafe is the fact that Surefire would fail the build
in the integration-test phase, without taking down the server in the
post-integration-test phase.
This implementation uses Tomcat, but you may change this to your liking.
See http://cargo.codehaus.org/Maven2+plugin for more information.
</description>
<url>https://github.com/difi/oxalis</url>
<issueManagement>
<url>https://github.com/difi/oxalis/issues</url>
<system>GitHub Issues</system>
</issueManagement>
<organization>
<name>Norwegian Agency for Public Management and eGovernment (Difi)</name>
<url>http://www.difi.no/</url>
</organization>
<properties>
<servlet.port>18080</servlet.port>
</properties>
<dependencies>
<!-- Oxalis -->
<dependency>
<groupId>no.difi.oxalis</groupId>
<artifactId>oxalis-as2</artifactId>
</dependency>
<!-- The Oxalis web application -->
<dependency>
<groupId>no.difi.oxalis</groupId>
<artifactId>oxalis-inbound</artifactId>
<!-- <type>war</type> -->
<classifier>classes</classifier>
</dependency>
<!-- The outbound library of Oxalis -->
<dependency>
<groupId>no.difi.oxalis</groupId>
<artifactId>oxalis-outbound</artifactId>
</dependency>
<dependency>
<groupId>no.difi.oxalis</groupId>
<artifactId>oxalis-statistics</artifactId>
</dependency>
<dependency>
<groupId>no.difi.oxalis</groupId>
<artifactId>oxalis-test-impl</artifactId>
<scope>test</scope>
</dependency>
<!-- Apache HTTP Client -->
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
</dependency>
<!-- We need logging as well -->
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>jcl-over-slf4j</artifactId>
</dependency>
<dependency>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
</dependency>
</dependencies>
<build>
<pluginManagement>
<plugins>
<!-- Failsafe will execute tests in the integration-test phase, rather than in the test phase -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
</plugin>
<!-- Defines the general attributes of the Cargo plugin -->
<plugin>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<version>1.4.18</version>
<configuration>
<configuration>
<properties>
<cargo.servlet.port>${servlet.port}</cargo.servlet.port>
</properties>
</configuration>
<deployables>
<!-- References the dependencies section -->
<deployable>
<groupId>no.difi.oxalis</groupId>
<artifactId>oxalis-inbound</artifactId>
<type>war</type>
<properties>
<!-- Makes our application available at http://localhost:${servlet.port}/oxalis -->
<context>oxalis</context>
</properties>
</deployable>
</deployables>
<container>
<dependencies>
<!-- No external dependencies for now, used to list Metro here -->
</dependencies>
</container>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>
<profiles>
<profile>
<id>it-test</id>
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<configuration>
<container>
<containerId>tomcat9x</containerId>
<zipUrlInstaller>
<url>http://archive.apache.org/dist/tomcat/tomcat-9/v9.0.0.M15/bin/apache-tomcat-9.0.0.M15.zip</url>
</zipUrlInstaller>
</container>
<configuration>
<!-- Note: this will cause Tomcat to ONLY accept http on 8080 -->
<properties>
<cargo.servlet.port>${servlet.port}</cargo.servlet.port>
<cargo.protocol>http</cargo.protocol>
<cargo.tomcat.connector.clientAuth>false</cargo.tomcat.connector.clientAuth>
<cargo.logging>medium</cargo.logging>
</properties>
</configuration>
</configuration>
<dependencies>
</dependencies>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<!-- Concrete configuration of failsafe-plugin -->
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
<executions>
<execution>
<id>perform-it</id>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
<configuration>
<systemProperties>
<property>
<name>servlet.port</name>
<value>${servlet.port}</value>
</property>
</systemProperties>
<excludedGroups>none,difi,manual</excludedGroups>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<!-- See also the pluginManagement section above -->
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<executions>
<execution>
<!-- Starts the web container in the pre-integration-test phase -->
<id>start-cargo</id>
<phase>pre-integration-test</phase>
<goals>
<goal>start</goal>
</goals>
<configuration>
<configuration>
<properties>
<cargo.logging>medium</cargo.logging>
</properties>
</configuration>
</configuration>
</execution>
<execution>
<!-- Stops the web container in the post-integration-test phase -->
<id>stop-cargo</id>
<phase>post-integration-test</phase>
<goals>
<goal>stop</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>