<?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">
  <modelVersion>4.0.0</modelVersion>
  <parent>
    <groupId>org.squashtest.tm</groupId>
    <artifactId>squash-tm-plugins</artifactId>
    <version>1.12.1.RC2</version>
  </parent>
  <artifactId>plugin.report.std</artifactId>
  <packaging>bundle</packaging>
  <description>Standard (default) reports for Squash TM</description>

  <properties>
    <jasperreports.build.outputDirectory>${project.build.outputDirectory}/jasperreports</jasperreports.build.outputDirectory>
  </properties>

  <dependencies>
    <dependency>
      <groupId>javax.inject</groupId>
      <artifactId>com.springsource.javax.inject</artifactId>
    </dependency>
    <!-- ====== /DEPENDENCY POMS ====== -->

    <!--======= SQUASHTEST MODULES ======== -->
    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>core.api</artifactId>
      <version>${project.version}</version>
    </dependency>
    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>core.report.api</artifactId>
      <version>${project.version}</version>
    </dependency>
    <dependency>
      <groupId>org.squashtest.tm</groupId>
      <artifactId>hibernate-dependencies</artifactId>
      <version>${project.version}</version>
      <type>pom</type>
    </dependency>
    <!--======= /SQUASHTEST MODULES ======== -->

    <dependency>
      <groupId>org.springframework</groupId>
      <artifactId>org.springframework.beans</artifactId>
      <scope>compile</scope>
    </dependency>

    <!-- For legacy report -->
    <dependency>
      <groupId>org.springframework</groupId>
      <artifactId>org.springframework.transaction</artifactId>
      <scope>compile</scope>
    </dependency>
    <!-- ====== DEPENDENCY POMS ====== -->
    <dependency>
      <groupId>org.squashtest.tm</groupId>
      <artifactId>springdm-bundle-dependencies</artifactId>
      <version>${project.version}</version>
      <type>pom</type>
    </dependency>
    <dependency>
      <groupId>org.squashtest.tm</groupId>
      <artifactId>tm.domain</artifactId>
      <version>${project.version}</version>
    </dependency>
    <dependency>
      <groupId>org.squashtest.tm</groupId>
      <artifactId>tm.service</artifactId>
      <version>${project.version}</version>
    </dependency>

    <!-- Required to compile reports -->
    <dependency>
      <groupId>net.sf.jasperreports</groupId>
      <artifactId>jasperreports</artifactId>
      <scope>provided</scope>
      <optional>true</optional>
    </dependency>
    <dependency>
      <groupId>org.squashtest.tm</groupId>
      <artifactId>org.squashtest.csp.tools.unittest</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.squashtest.tm</groupId>
      <artifactId>spock-test-dependencies</artifactId>
      <version>${project.version}</version>
      <type>pom</type>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>

    <testSourceDirectory>src/test/groovy</testSourceDirectory>
    <resources>
      <resource>
        <filtering>true</filtering>
        <directory>src/main/resources</directory>
      </resource>
      <!-- <resource> <directory>target/jasperreports-generated</directory> 
				<targetPath>target/jasperreports</targetPath> <filtering>false</filtering> 
				</resource> -->
    </resources>

    <testResources>
      <testResource>
        <filtering>false</filtering>
        <directory>src/test/resources</directory>
      </testResource>
    </testResources>

    <plugins>

      <!-- ====== SPOCK TESTS ====== -->
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
      </plugin>
      <!-- ====== /SPOCK TESTS ====== -->

      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>jasperreports-maven-plugin</artifactId>
        <executions>
          <execution>
            <goals>
              <goal>compile-reports</goal>
            </goals>
            <configuration>
              <outputDirectory>${jasperreports.build.outputDirectory}</outputDirectory>
            </configuration>
          </execution>
        </executions>
      </plugin>

      <plugin>
        <groupId>org.apache.felix</groupId>
        <artifactId>maven-bundle-plugin</artifactId>
        <extensions>true</extensions>
        <configuration>
          <instructions>
            <_include>bnd.bnd</_include>
          </instructions>
        </configuration>
      </plugin>
    </plugins>
  </build>
</project>
