<?xml version="1.0" encoding="UTF-8"?>
<!--
    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.
    
    $Id: pom.xml 1742341 2016-05-04 23:47:06Z taylor $
-->
<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>
  <prerequisites>
    <maven>2.0.9</maven>
  </prerequisites>

  <artifactId>jetspeed-page-manager</artifactId>
  <name>Jetspeed-2 Page Manager</name>
  <description>
        Page management implementations.
    </description>
  <parent>
    <groupId>org.apache.portals.jetspeed-2</groupId>
    <artifactId>components</artifactId>
    <version>2.3.1</version>
  </parent>
  <packaging>jar</packaging>

  <!-- Dependencies -->

  <dependencies>

    <!-- Build Dependencies -->
    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>jetspeed-api</artifactId>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>jetspeed-commons</artifactId>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>jetspeed-rdbms</artifactId>
    </dependency>
    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>jetspeed-file-cache</artifactId>
    </dependency>
    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>jetspeed-security</artifactId>
    </dependency>
    <dependency>
      <groupId>org.codehaus.castor</groupId>
      <artifactId>castor</artifactId>
    </dependency>
    <dependency>
      <groupId>dom4j</groupId>
      <artifactId>dom4j</artifactId>
    </dependency>
    <dependency>
      <groupId>commons-collections</groupId>
      <artifactId>commons-collections</artifactId>
    </dependency>
    <dependency>
      <groupId>commons-lang</groupId>
      <artifactId>commons-lang</artifactId>
    </dependency>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
    </dependency>

    <!-- Test Dependencies -->
    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>jetspeed-id-generator</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>xerces</groupId>
      <artifactId>xercesImpl</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>xalan</groupId>
      <artifactId>xalan</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.geronimo.specs</groupId>
      <artifactId>geronimo-jta_1.1_spec</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>${org.apache.jetspeed.test.jdbc.driver.groupId}</groupId>
      <artifactId>${org.apache.jetspeed.test.jdbc.driver.artifactId}</artifactId>
      <version>${org.apache.jetspeed.test.jdbc.driver.version}</version>
      <scope>test</scope>
    </dependency>
    <!--
      Note: tyrex and junit is normally required only for test, but in this case, abstract test cases are included in
      the component build... this should probably be fixed... for now, assume that junit will be provided if these test
      classes are used.
    -->
    <dependency>
      <groupId>tyrex</groupId>
      <artifactId>tyrex</artifactId>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.commons</groupId>
      <artifactId>commons-jexl</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-log4j12</artifactId>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
        <configuration>
          <forkMode>always</forkMode>
          <excludes>
            <exclude>**/*$*</exclude>
            <exclude>**/PageManagerTestShared.java</exclude>
            <exclude>**/DirectoryXMLTransform.java</exclude>
          </excludes>
        </configuration>
      </plugin>
      <plugin>
        <groupId>${project.groupId}</groupId>
        <artifactId>jetspeed-unpack-maven-plugin</artifactId>
        <version>${project.version}</version>
        <executions>
          <execution>
            <id>unpack-test-resources</id>
            <goals>
              <goal>unpack</goal>
            </goals>
            <phase>process-test-resources</phase>
            <configuration>
              <skip>${skipTests}</skip>
              <unpack>
                <artifact>${project.groupId}:jetspeed-portal-resources:jar</artifact>
                <targetDirectory>${project.build.directory}</targetDirectory>
                <resources>
                  <resource>
                    <path>assembly</path>
                    <include>transaction.xml,boot/datasource.xml</include>
                    <destination>test-classes</destination>
                  </resource>
                  <resource>
                    <path>db-ojb</path>
                    <exclude>ehcache.xml,distributed-ehcache.xml</exclude>
                    <destination>test-classes</destination>
                  </resource>
                </resources>
              </unpack>
            </configuration>
          </execution>
        </executions>
        <dependencies>
          <dependency>
            <groupId>${project.groupId}</groupId>
            <artifactId>jetspeed-portal-resources</artifactId>
            <version>${project.version}</version>
          </dependency>
        </dependencies>
      </plugin>
    </plugins>
  </build>
</project>
