<?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/maven-v4_0_0.xsd">
  <modelVersion>4.0.0</modelVersion>
  <parent>
    <groupId>au.com.acegi</groupId>
    <artifactId>acegi-standard-project</artifactId>
    <version>0.6.2</version>
  </parent>
  <artifactId>acegi-standard-test</artifactId>
  <packaging>pom</packaging>
  <name>Acegi Standard Project: Test</name>
  <build>
    <plugins>
      <!-- we shouldn't deploy acegi-standard-test, but this Nexus bug leave us no alternative: https://issues.sonatype.org/browse/NEXUS-9138
      <plugin>
        <groupId>org.sonatype.plugins</groupId>
        <artifactId>nexus-staging-maven-plugin</artifactId>
        <configuration>
          <skipNexusStagingDeployMojo>true</skipNexusStagingDeployMojo>
        </configuration>
      </plugin>
      -->
    </plugins>
  </build>
  <profiles>
    <profile>
      <id>acegi-standard-project-build-invoker</id>
      <activation>
        <file>
          <exists>src/it/acegi-internal/pom.xml</exists>
        </file>
      </activation>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-invoker-plugin</artifactId>
            <configuration>
              <cloneProjectsTo>${project.build.directory}/it</cloneProjectsTo>
              <settingsFile>src/it/settings.xml</settingsFile>
              <localRepositoryPath>${project.build.directory}/local-repo</localRepositoryPath>
              <postBuildHookScript>verify</postBuildHookScript>
              <noLog>false</noLog>
              <showErrors>true</showErrors>
            </configuration>
            <executions>
              <execution>
                <id>integration-test</id>
                <goals>
                  <goal>install</goal>
                  <goal>run</goal>
                </goals>
                <configuration>
                  <goals>
                    <goal>verify</goal>
                  </goals>
                </configuration>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>
</project>
