<?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>com.atlassian.amps</groupId>
        <artifactId>atlassian-amps-product-plugins</artifactId>
        <version>8.11.1</version>
    </parent>

    <groupId>com.atlassian.maven.plugins</groupId>
    <artifactId>bitbucket-maven-plugin</artifactId>
    <packaging>maven-plugin</packaging>

    <name>Bitbucket Maven Plugin</name>

    <dependencies>
        <dependency>
            <groupId>com.atlassian.maven.archetypes</groupId>
            <artifactId>bitbucket-plugin-archetype</artifactId>
            <scope>runtime</scope>
        </dependency>
        <dependency>
            <groupId>com.sun.xml.bind</groupId>
            <artifactId>jaxb-impl</artifactId>
        </dependency>
    </dependencies>

    <profiles>
        <profile>
            <id>invoker</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-dependency-plugin</artifactId>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-resources-plugin</artifactId>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-invoker-plugin</artifactId>
                        <configuration>
                            <scriptVariables>
                                <artifactId>${invoker.artifactId}</artifactId>
                                <product>${invoker.product}</product>
                            </scriptVariables>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
            <properties>
                <invoker.product>bitbucket</invoker.product>
                <product.version>${bitbucket.version}</product.version>
                <product.data.version>${bitbucket.data.version}</product.data.version>
            </properties>
        </profile>
        <!-- The invoker tests are split into two batches so that they can be run in parallel Bamboo jobs -->
        <profile>
            <id>invoker-batch-1</id>
            <properties>
                <invoker.test>
                    achooTest,
                    compressLocalizedResourcesTest,
                    compressResourcesWithIncludeParamTest,
                    copyBundledDependenciesTest,
                    createOsgiJavaConfigTest,
                    createTest,
                    debugTest,
                    filterPluginDescriptorWithPluginDescriptorTest,
                    filterPluginDescriptorWithoutPluginDescriptorTest,
                    generateManifestWithNoInstructionsTest,
                    generateRestDocsTest,
                    integrationTest,
                    quickreloadTest,
                    remoteTest,
                    runParallelTest,
                    validateBannedDependenciesTest,
                    validateManifestSkipValidationTest,
                    validateManifestWithInvalidManifestTest,
                    validateManifestWithValidManifestTest
                </invoker.test>
            </properties>
        </profile>
        <profile>
            <id>invoker-batch-2</id>
            <properties>
                <invoker.test>
                    compressResourcesTest,
                    compressResourcesWithClosureOptionLanguageInTest,
                    debugWithPortConflictTest,
                    debugWithTestGroupTest,
                    extractDependenciesTest,
                    generateManifestWhenDependencyContainsModuleInfoTest,
                    generateManifestWithInstructionsTest,
                    generateObrTest,
                    integrationTestWithPortConflictTest,
                    integrationTestWithTestGroupTest,
                    jarWithExistingManifestTest,
                    runTest,
                    runWithPortConflictTest,
                    unitTest,
                    validateBannedDependenciesWithBannedTest
                </invoker.test>
            </properties>
        </profile>
    </profiles>
</project>
