<!--
  ~ Licensed to the Apache Software Foundation (ASF) under one
  ~ or more contributor license agreements.  See the NOTICE file
  ~ distributed with this work for additional information
  ~ regarding copyright ownership.  The ASF licenses this file
  ~ to you under the Apache License, Version 2.0 (the
  ~ "License"); you may not use this file except in compliance
  ~ with the License.  You may obtain a copy of the License at
  ~
  ~     http://www.apache.org/licenses/LICENSE-2.0
  ~
  ~ Unless required by applicable law or agreed to in writing,
  ~ software distributed under the License is distributed on an
  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  ~ KIND, either express or implied.  See the License for the
  ~ specific language governing permissions and limitations
  ~ under the License.
  -->

<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">
  <modelVersion>4.0.0</modelVersion>

  <parent>
    <groupId>org.apache.maven.surefire</groupId>
    <artifactId>surefire-providers</artifactId>
    <version>2.12.4</version>
    <relativePath>../pom.xml</relativePath>
  </parent>

  <artifactId>surefire-testng</artifactId>

  <name>SureFire TestNG Runner</name>

  <dependencies>
    <dependency>
      <groupId>org.apache.maven</groupId>
      <artifactId>maven-artifact</artifactId>
      <version>2.0</version>
    </dependency>
    <dependency>
      <groupId>org.apache.maven.surefire</groupId>
      <artifactId>surefire-testng-utils</artifactId>
      <version>${project.version}</version>
    </dependency>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>3.8.2</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.maven.surefire</groupId>
      <artifactId>maven-surefire-common</artifactId>
    </dependency>
  </dependencies>

  <build>
    <resources>
      <resource>
        <directory>src/main/resources/META-INF</directory>
        <targetPath>META-INF</targetPath>
      </resource>
    </resources>

    <plugins>
      <plugin>
        <artifactId>maven-compiler-plugin</artifactId>
        <configuration>
          <fork>false</fork>
          <compilerVersion>1.4</compilerVersion>
          <source>1.4</source>
          <target>1.4</target>
        </configuration>
      </plugin>
      <plugin>
        <artifactId>maven-surefire-plugin</artifactId>
        <configuration>
          <!-- DGF There are no tests in this project currently, and this
            resolves SUREFIRE-414 -->
          <skipExec>true</skipExec>
        </configuration>
      </plugin>
    </plugins>
  </build>

  <!-- TODO: do we include both? Or just 1.5? No need for profile -->
  <profiles>
    <profile>
      <id>jdk14</id>
      <activation>
        <jdk>1.4</jdk>
      </activation>
      <dependencies>
        <dependency>
          <groupId>org.testng</groupId>
          <artifactId>testng</artifactId>
          <version>5.7</version>
          <classifier>jdk14</classifier>
        </dependency>
      </dependencies>
    </profile>
    <profile>
      <id>jdk15</id>
      <activation>
        <jdk>!1.4</jdk>
      </activation>
      <dependencies>
        <dependency>
          <groupId>org.testng</groupId>
          <artifactId>testng</artifactId>
          <version>5.7</version>
          <classifier>jdk15</classifier>
        </dependency>
      </dependencies>
    </profile>
  </profiles>
</project>
