<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>
  <groupId>org.duracloud</groupId>
  <artifactId>integration-test</artifactId>
  <version>3.2.2</version>
  <name>Integration Test</name>

  <parent>
    <artifactId>duracloud</artifactId>
    <groupId>org.duracloud</groupId>
    <version>3.2.2</version>
    <relativePath>../pom.xml</relativePath>
  </parent>

  <build>
    <plugins>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
        <executions>
          <execution>
            <id>integrationtest</id>
            <phase>integration-test</phase>
            <goals>
              <goal>test</goal>
            </goals>

            <configuration>
              <testFailureIgnore>true</testFailureIgnore>
              <systemProperties>
                <property>
                  <name>unit.database.home</name>
                  <value>${unit.database.home.default}</value>
                </property>
                <property>
                  <name>unit.database.password</name>
                  <value>${unit.database.password.default}</value>
                </property>
                <property>
                  <name>PROJECT_VERSION</name>
                  <value>${project.version}</value>
                </property>
              </systemProperties>
              <excludes>
                <exclude>${unitTests}</exclude>
                <exclude>${instrumentedTests}</exclude>
                <exclude>${innerClasses}</exclude>
                <exclude>${servicesAdminTests}</exclude>
              </excludes>
              <includes>
                <include>${integrationTests}</include>
              </includes>
            </configuration>

          </execution>
        </executions>
      </plugin>

    </plugins>
  </build>

  <profiles>

    <profile>
      <id>skipIntTests</id>
      <activation>
                <!--The integration tests have been disabled until they run with success, consistently-->
        <activeByDefault>true</activeByDefault>
        <property>
          <name>skipIntTests</name>
        </property>
      </activation>
      <build>
        <plugins>

          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-surefire-plugin</artifactId>
            <executions>
              <execution>
                <id>integrationtest</id>
                <phase>none</phase>
              </execution>
            </executions>
          </plugin>

        </plugins>
      </build>
    </profile>

  </profiles>

  <dependencies>

        <!-- internal projects -->
    <dependency>
      <groupId>org.duracloud</groupId>
      <artifactId>storeclient</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.duracloud</groupId>
      <artifactId>common-rest</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.duracloud</groupId>
      <artifactId>storageprovider</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.duracloud</groupId>
      <artifactId>common</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.duracloud</groupId>
      <artifactId>chunk</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.duracloud</groupId>
      <artifactId>security</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>


    <dependency>
      <groupId>org.duracloud</groupId>
      <artifactId>durastore</artifactId>
      <version>${project.version}</version>
      <classifier>for-integration-test</classifier>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.duracloud</groupId>
      <artifactId>duradmin</artifactId>
      <version>${project.version}</version>
      <classifier>for-integration-test</classifier>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.duracloud</groupId>
      <artifactId>common-db</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.duracloud</groupId>
      <artifactId>s3storageprovider</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.duracloud</groupId>
      <artifactId>rackspacestorageprovider</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.duracloud</groupId>
      <artifactId>synctool</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <groupId>log4j</groupId>
          <artifactId>log4j</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.slf4j</groupId>
          <artifactId>slf4j-log4j12</artifactId>
        </exclusion>
      </exclusions>
    </dependency>

    <dependency>
      <groupId>org.duracloud</groupId>
      <artifactId>app-config</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.duracloud</groupId>
      <artifactId>unit-test-db</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>com.amazonaws</groupId>
      <artifactId>aws-java-sdk</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>commons-io</groupId>
      <artifactId>commons-io</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>commons-httpclient</groupId>
      <artifactId>commons-httpclient</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.jdom</groupId>
      <artifactId>jdom</artifactId>
      <scope>test</scope>
    </dependency>

  </dependencies>
</project>
