<?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>
    <artifactId>as2-utils</artifactId>
    <name>as2-utils</name>
    <packaging>jar</packaging>


    <parent>
        <groupId>com.mulesoft.connectors</groupId>
        <artifactId>as2-support-parent</artifactId>
        <version>3.0.0</version>
        <relativePath>../pom.xml</relativePath>
    </parent>

    <properties>
        <mule.runtime.version>4.3.0</mule.runtime.version>
        <muleApiVersion>1.3.0</muleApiVersion>
        <bouncy.castle.version>1.82</bouncy.castle.version>
    </properties>


    <dependencies>
        <dependency>
            <groupId>${project.groupId}</groupId>
            <artifactId>as2-bc-facade</artifactId>
            <version>${project.version}</version>
        </dependency>
        <!-- Test dependency to access test utilities from as2-bc-facade -->
        <dependency>
            <groupId>${project.groupId}</groupId>
            <artifactId>as2-bc-facade</artifactId>
            <version>${project.version}</version>
            <type>test-jar</type>
            <scope>test</scope>
        </dependency>
        <!-- For unit tests, use the BC 1.7 implementation so the factory can initialize -->
        <dependency>
            <groupId>${project.parent.groupId}</groupId>
            <artifactId>as2-bc-non-fips-impl</artifactId>
            <version>${project.version}</version>
            <scope>test</scope>
        </dependency>
        <!-- BC providers moved under non-fips profile -->
        <!-- https://mvnrepository.com/artifact/org.mule.runtime/mule-core -->
        <dependency>
            <groupId>org.mule.runtime</groupId>
            <artifactId>mule-core</artifactId>
            <version>${mule.runtime.version}</version>
            <scope>provided</scope>
        </dependency>
        <!-- https://mvnrepository.com/artifact/org.mule.runtime/mule-service-http-api -->
        <dependency>
            <groupId>org.mule.runtime</groupId>
            <artifactId>mule-service-http-api</artifactId>
            <version>${mule.runtime.version}</version>
            <scope>provided</scope>
        </dependency>

        <!-- Test Dependencies -->
        <dependency>
            <groupId>pl.pragmatists</groupId>
            <artifactId>JUnitParams</artifactId>
            <version>1.1.1</version>
            <scope>test</scope>
        </dependency>
        <!-- https://mvnrepository.com/artifact/org.hamcrest/hamcrest-all -->
        <dependency>
            <groupId>org.hamcrest</groupId>
            <artifactId>hamcrest-all</artifactId>
            <version>1.3</version>
            <scope>test</scope>
        </dependency>
        <!-- https://mvnrepository.com/artifact/org.mockito/mockito-core -->
        <dependency>
            <groupId>org.mockito</groupId>
            <artifactId>mockito-core</artifactId>
            <version>${mockito.version}</version>
            <scope>test</scope>
        </dependency>
        <!-- https://mvnrepository.com/artifact/commons-codec/commons-codec -->
        <dependency>
            <groupId>commons-codec</groupId>
            <artifactId>commons-codec</artifactId>
            <version>1.13</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.bouncycastle</groupId>
            <artifactId>bcpkix-jdk18on</artifactId>
            <version>${bouncy.castle.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.bouncycastle</groupId>
            <artifactId>bcprov-jdk18on</artifactId>
            <version>${bouncy.castle.version}</version>
            <scope>test</scope>
        </dependency>
    </dependencies>

    <build>
        <plugins>
            <plugin>
                <groupId>org.jacoco</groupId>
                <artifactId>jacoco-maven-plugin</artifactId>
                <executions>
                    <execution>
                        <id>report</id>
                        <goals>
                            <goal>report-aggregate</goal>
                        </goals>
                        <phase>verify</phase>
                    </execution>
                </executions>
            </plugin>
        </plugins>
        <pluginManagement>
            <plugins>
                <plugin>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>3.7.0</version>
                    <configuration>
                        <source>${jdk.version}</source>
                        <target>${jdk.version}</target>
                        <encoding>${project.build.sourceEncoding}</encoding>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>2.22.2</version>
                    <executions>
                        <execution>
                            <id>surefire-test</id>
                            <phase>test</phase>
                            <goals>
                                <goal>test</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>
            </plugins>
        </pluginManagement>
    </build>
</project>
