<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>
    <packaging>pom</packaging>
    <name>Tomahawk Examples Project</name>
    <groupId>org.apache.myfaces.tomahawk</groupId>
    <artifactId>tomahawk-examples-project</artifactId>

    <parent>
        <groupId>org.apache.myfaces.tomahawk</groupId>
        <artifactId>tomahawk-project</artifactId>
        <version>1.1.14</version>
    </parent>

    <scm>
        <connection>scm:svn:http://svn.apache.org/repos/asf/myfaces/tomahawk/tags/tomahawk-project-1.1.14/examples</connection>
        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/myfaces/tomahawk/tags/tomahawk-project-1.1.14/examples</developerConnection>
        <url>http://svn.apache.org/viewcvs.cgi/myfaces/tomahawk/tags/tomahawk-project-1.1.14/examples</url>
    </scm>

    <modules>
        <module>blank</module>
        <module>simple</module>
        <module>simple20</module>
        <module>tiles</module>
        <module>wap</module>
    </modules>

    <profiles>
        <!-- See: http://myfaces.apache.org/tomahawk/testing/hostedqa.html -->
        <profile>
            <id>hostedqa</id>
            <dependencies>
                <dependency>
                    <groupId>com.hostedqa</groupId>
                    <artifactId>hostedqa-remote-ant</artifactId>
                    <version>1.7</version>
                    <scope>test</scope>
                </dependency>
            </dependencies>
            <build>
                <plugins>
                    <plugin>
                        <artifactId>maven-antrun-plugin</artifactId>
                        <groupId>org.apache.maven.plugins</groupId>
                        <executions>
                            <execution>
                                <phase>package</phase>
                                <goals>
                                    <goal>run</goal>
                                </goals>
                                <configuration>
                                    <tasks>
                                        <taskdef resource="hostedqatasks" classpathref="maven.plugin.classpath" />
                                        <upload file="${project.build.directory}/${project.build.finalName}.war" account="myfaces" email="${myfaces.hostedqa.email}" password="${myfaces.hostedqa.password}" resourceId="${hostedqa.resourceId}" />

                                        <playsuite clientConfigs="${hostedqa.clientConfigs}" appConfigs="${hostedqa.appConfigs}" account="myfaces" email="${myfaces.hostedqa.email}" password="${myfaces.hostedqa.password}">
                                            <fileSet dir="${basedir}/src/test/selenium" excludes="TestSuite*.html,*FireFox.html" />
                                        </playsuite>
                                    </tasks>
                                </configuration>
                            </execution>
                        </executions>
                        <dependencies>
                            <dependency>
                                <groupId>com.hostedqa</groupId>
                                <artifactId>hostedqa-remote-ant</artifactId>
                                <version>1.7</version>
                            </dependency>
                        </dependencies>
                    </plugin>
                </plugins>
            </build>
        </profile>
        <!-- This profile is invoked by -DprepareRelease=true.  This allows mvn release:prepare to
              run successfully on the assembly projects. -->
        <profile>
            <id>prepare-release</id>
            <activation>
                <property>
                    <name>prepareRelease</name>
                </property>
            </activation>
            <modules>
                <module>assembly</module>
            </modules>
            <build>
                <plugins>
                    <plugin>
                        <artifactId>maven-release-plugin</artifactId>
                        <configuration>
                            <arguments>-DprepareRelease</arguments>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
        <profile>
            <id>perform-release</id>
            <activation>
                <property>
                    <name>performRelease</name>
                    <value>true</value>
                </property>
            </activation>
            <modules>
                <module>assembly</module>
            </modules>
            <build>
                <plugins>
                    <plugin>
                        <artifactId>maven-release-plugin</artifactId>
                        <configuration>
                            <arguments>-Papache-release -DperformRelease</arguments>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

</project>
