<?xml version="1.0" encoding="UTF-8"?>
<!-- 
Copyright 2013 Dan Haywood

Licensed 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/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <parent>
        <groupId>org.sonatype.oss</groupId>
        <artifactId>oss-parent</artifactId>
        <version>7</version>
    </parent>

    <groupId>com.danhaywood.java</groupId>
    <artifactId>danhaywood-java-testsupport</artifactId>
    <version>1.0.0</version>
    <packaging>jar</packaging>

    <name>Java Test Support</name>
    <description>
        A collection of utilities for writing Java tests.
        Intended to be added as a dependency with scope=test only. 
        If using the DBUnitRule feature, also explicitly include dependency to 
        org.dbunit:dbunit
    </description>

    <url>https://github.com/danhaywood/java-testsupport</url>
    <licenses>
        <license>
            <name>The Apache Software License, Version 2.0</name>
            <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
            <distribution>repo</distribution>
        </license>
    </licenses>
    <scm>
        <connection>scm:git:https://github.com/danhaywood/java-testsupport.git</connection>
        <developerConnection>scm:git:https://github.com/danhaywood/java-testsupport.git</developerConnection>
        <url>https://github.com/danhaywood/java-testsupport.git</url>
    </scm>
    <developers>
        <developer>
            <id>danhaywood</id>
            <name>Dan Haywood</name>
            <email>dan@haywood-associates.co.uk</email>
        </developer>
    </developers>

    <properties>
        <compileSource>1.6</compileSource>
        <compileTarget>1.6</compileTarget>
    </properties>

    <build>
        <resources>
            <resource>
                <filtering>false</filtering>
                <directory>src/main/resources</directory>
            </resource>
            <resource>
                <filtering>false</filtering>
                <directory>src/main/java</directory>
                <includes>
                    <include>**</include>
                </includes>
                <excludes>
                    <exclude>**/*.java</exclude>
                </excludes>
            </resource>
        </resources>
        <pluginManagement>
            <plugins>
                <plugin>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>2.3.1</version>
                    <configuration>
                        <showDeprecation>false</showDeprecation>
                        <showWarnings>false</showWarnings>
                        <source>${compileSource}</source>
                        <target>${compileTarget}</target>
                    </configuration>
                </plugin>
                <plugin>
                    <artifactId>maven-jar-plugin</artifactId>
                    <version>2.3.1</version>
                    <executions>
                        <execution>
                            <id>package-test-jar</id>
                            <phase>package</phase>
                            <goals>
                                <goal>test-jar</goal>
                            </goals>
                        </execution>
                    </executions>
                    <configuration>
                        <archive>
                            <manifest>
                                <addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
                                <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
                            </manifest>
                        </archive>
                    </configuration>
                </plugin>

                <plugin>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>2.1.2</version>
                    <executions>
                        <execution>
                            <id>package-jars</id>
                            <phase>package</phase>
                            <goals>
                                <goal>jar</goal>
                                <goal>test-jar</goal>
                            </goals>
                            <configuration>
                                <includePom>true</includePom>
                            </configuration>
                        </execution>
                    </executions>
                    <configuration>
                        <includePom>true</includePom>
                    </configuration>
                </plugin>

                <plugin>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <version>2.8</version>
                    <inherited>true</inherited>
                    <executions>
                        <execution>
                            <id>package-jars</id>
                            <phase>package</phase>
                            <goals>
                                <goal>jar</goal>
                                <goal>test-jar</goal>
                            </goals>
                            <configuration>
                                <includePom>true</includePom>
                            </configuration>
                        </execution>
                    </executions>
                    <configuration>
                        <debug>true</debug>
                        <minmemory>128m</minmemory>
                        <maxmemory>1024m</maxmemory>
                        <quiet>true</quiet>
                        <doctitle>${project.name} ${project.version}</doctitle>
                        <windowtitle>${project.name} ${project.version}</windowtitle>
                        <testDoctitle>${project.name} ${project.version} (TEST API)</testDoctitle>
                        <testWindowtitle>${project.name} ${project.version} (TEST API)</testWindowtitle>
                        <splitindex>true</splitindex>
                        <encoding>${project.build.sourceEncoding}</encoding>
                        <links>
                            <link>http://java.sun.com/j2se/1.6.0/docs/api</link>
                            <link>http://java.sun.com/j2se/1.5.0/docs/api</link>
                            <link>http://java.sun.com/j2se/1.4.2/docs/api</link>
                            <link>http://java.sun.com/j2ee/1.4/docs/api</link>
                        </links>
                        <linksource>true</linksource>
                        <detectOfflineLinks>false</detectOfflineLinks>
                    </configuration>
                </plugin>
            </plugins>
        </pluginManagement>
        <plugins>
            <plugin>
                <artifactId>maven-source-plugin</artifactId>
            </plugin>
            <plugin>
                <artifactId>maven-javadoc-plugin</artifactId>
            </plugin>
        </plugins>
    </build>

    <dependencies>
        <dependency>
            <!-- Common Public License - v 1.0 -->
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.11</version>
        </dependency>

        <dependency>
            <!-- ASL v2.0 -->
            <groupId>org.mvel</groupId>
            <artifactId>mvel2</artifactId>
            <version>2.1.6.Final</version>
        </dependency>
    
        <dependency>
            <!-- GNU Lesser General Public License, Version 2.1 -->
            <groupId>org.dbunit</groupId>
            <artifactId>dbunit</artifactId>
            <version>2.4.9</version>
            <!-- 
            marked as optional due to the license; include explicitly
            -->
            <optional>true</optional>
        </dependency>

        <dependency>
            <!-- ASL v2.0 -->
            <groupId>com.google.guava</groupId>
            <artifactId>guava</artifactId>
            <version>14.0.1</version>
        </dependency>

        <dependency>
            <!-- ASL v2.0 -->
            <groupId>org.codehaus.jackson</groupId>
            <artifactId>jackson-core-asl</artifactId>
            <version>1.9.12</version>
        </dependency>

        <dependency>
            <!-- ASL v2.0 -->
            <groupId>org.codehaus.jackson</groupId>
            <artifactId>jackson-mapper-asl</artifactId>
            <version>1.9.12</version>
        </dependency>

        <dependency>
            <!-- ASL v2.0 -->
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
            <version>1.7.5</version>
        </dependency>

        <dependency>
            <!-- ASL v2.0 -->
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-nop</artifactId>
            <version>1.7.5</version>
        </dependency>
    
        <dependency>
            <groupId>org.hsqldb</groupId>
            <artifactId>hsqldb</artifactId>
            <version>2.2.9</version>
            <scope>test</scope>
        </dependency>

    </dependencies>

    <profiles>
        <profile>
            <id>m2e</id>
            <activation>
                <property>
                    <name>m2e.version</name>
                </property>
            </activation>
            <build>
                <directory>target-ide</directory>
            </build>
        </profile>
    </profiles>

</project>
