two-versions-parent
Used in:
components
- OverviewOverview
- VersionsVersions
- DependentsDependents
- DependenciesDependencies
<dependency>
<groupId>org.elasticsearch.qa.backwards</groupId>
<artifactId>two-versions-parent</artifactId>
<version>2.4.6</version>
</dependency><?xml version="1.0" encoding="UTF-8"?>
<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/xsd/maven-4.0.0.xsd">
<parent>
<groupId>org.elasticsearch.qa.backwards</groupId>
<artifactId>parent</artifactId>
<version>2.4.6</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>two-versions-parent</artifactId>
<name>QA: BWC: Two Versions Parent</name>
<description>Backwards compatibility tests involving the current version
being built and some previous version</description>
<packaging>pom</packaging>
<!-- To use this simply declare it as a parent pom, define
$tests.bwc.version, and set $skip.integ.tests to $skipTests. See 2.0.0
for an example. -->
<dependencies>
<dependency>
<groupId>org.elasticsearch.distribution.tar</groupId>
<artifactId>elasticsearch</artifactId>
<version>${project.version}</version>
<type>tar.gz</type>
<scope>test</scope>
</dependency>
<dependency>
<!-- This just picks up ExternalNodeService which is all we need because
we grab the tests using testClassesDirectory. -->
<groupId>org.elasticsearch.qa.backwards</groupId>
<artifactId>shared</artifactId>
<version>${project.version}</version>
</dependency>
</dependencies>
<build>
<testResources>
<testResource>
<directory>src/test/resources</directory>
</testResource>
<!-- shared test resources like log4j.properties -->
<testResource>
<directory>${elasticsearch.tools.directory}/shared-test-resources</directory>
<filtering>false</filtering>
</testResource>
</testResources>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>integ-setup-dependencies</id>
<phase>pre-integration-test</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<skip>${skip.integ.tests}</skip>
<useBaseVersion>true</useBaseVersion>
<outputDirectory>${integ.deps}/plugins</outputDirectory>
<artifactItems>
<artifactItem>
<groupId>org.elasticsearch.distribution.tar</groupId>
<artifactId>elasticsearch</artifactId>
<version>${project.version}</version>
<type>tar.gz</type>
<overWrite>true</overWrite>
<outputDirectory>${tests.bwc.path}</outputDirectory>
</artifactItem>
<artifactItem>
<groupId>org.elasticsearch.distribution.tar</groupId>
<artifactId>elasticsearch</artifactId>
<version>${tests.bwc.version}</version>
<type>tar.gz</type>
<outputDirectory>${tests.bwc.path}</outputDirectory>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>1.4.0</version>
<executions>
<execution>
<id>start-external-node-service</id>
<!-- Here we use exec:java with cleanupDaemonThreads=false and noblock
to _start_ ExternalNodeService and let it run until the build ends. -->
<goals>
<goal>java</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<skip>${skip.integ.tests}</skip>
<mainClass>org.elasticsearch.test.ExternalNodeService</mainClass>
<cleanupDaemonThreads>false</cleanupDaemonThreads>
<arguments>
<argument>${basedir}/${tests.bwc.path}</argument>
<argument>noblock</argument>
</arguments>
<!-- Use the test scop to pick up log4j configuration -->
<classpathScope>test</classpathScope>
</configuration>
</execution>
<execution>
<id>stop-external-node-service</id>
<goals>
<goal>java</goal>
</goals>
<phase>post-integration-test</phase>
<configuration>
<skip>${skip.integ.tests}</skip>
<mainClass>org.elasticsearch.test.ExternalNodeService</mainClass>
<arguments>
<argument>shutdown</argument>
</arguments>
<!-- Use the test scop to pick up log4j configuration -->
<classpathScope>test</classpathScope>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>com.carrotsearch.randomizedtesting</groupId>
<artifactId>junit4-maven-plugin</artifactId>
<executions>
<execution>
<id>integ-tests</id>
<configuration>
<!-- Paranoia around external clusters interfering with eachother -->
<!-- <parallelism>1</parallelism> -->
<testClassesDirectory>../shared/target/test-classes</testClassesDirectory>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>