<?xml version="1.0"?>
<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">
    <parent>
        <groupId>org.mule.tools.maven</groupId>
        <artifactId>mule-artifact-tools</artifactId>
        <version>3.3.1</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>

    <artifactId>mule-artifact-it</artifactId>
    <packaging>pom</packaging>
    <name>Mule Maven Plugin Integration Tests</name>


    <properties>
        <skipTests>${skipIntegrationTests}</skipTests>
        <licensePath>../LICENSE_HEADER.txt</licensePath>
        <formatterConfigPath>../formatter.xml</formatterConfigPath>
    </properties>

    <profiles>
        <profile>
            <id>default</id>
            <activation>
                <activeByDefault>true</activeByDefault>
            </activation>
            <modules>
                <module>mule-packager-it</module>
            </modules>
        </profile>
        <profile>
            <id>deployerIT</id>
            <modules>
                <module>mule-deployer-it</module>
            </modules>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-dependency-plugin</artifactId>
                        <version>${maven.dependency.plugin.version}</version>
                        <configuration>
                            <artifactItems>
                                <artifactItem>
                                    <groupId>com.mulesoft.mule.distributions</groupId>
                                    <artifactId>mule-ee-distribution-standalone</artifactId>
                                    <version>${mule.distribution.standalone.version}</version>
                                    <type>tar.gz</type>
                                    <outputDirectory>${project.build.directory}</outputDirectory>
                                </artifactItem>
                            </artifactItems>
                        </configuration>
                        <executions>
                            <execution>
                                <goals>
                                    <goal>unpack</goal>
                                </goals>
                                <phase>process-test-resources</phase>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
        <profile>
            <id>packagerIT</id>
            <modules>
                <module>mule-packager-it</module>
            </modules>
        </profile>
        <profile>
            <id>fullIntegration</id>
            <modules>
                <module>mule-packager-it</module>
                <module>mule-deployer-it</module>
            </modules>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-dependency-plugin</artifactId>
                        <version>${maven.dependency.plugin.version}</version>
                        <configuration>
                            <artifactItems>
                                <artifactItem>
                                    <groupId>com.mulesoft.mule.distributions</groupId>
                                    <artifactId>mule-ee-distribution-standalone</artifactId>
                                    <version>${mule.distribution.standalone.version}</version>
                                    <type>tar.gz</type>
                                    <outputDirectory>${project.build.directory}</outputDirectory>
                                </artifactItem>
                            </artifactItems>
                        </configuration>
                        <executions>
                            <execution>
                                <goals>
                                    <goal>unpack</goal>
                                </goals>
                                <phase>process-test-resources</phase>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

</project>
