<?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/maven-v4_0_0.xsd">
	<parent>
		<artifactId>samples</artifactId>
		<groupId>org.richfaces</groupId>
		<version>3.2.2.CR2</version>
	</parent>
	<modelVersion>4.0.0</modelVersion>
	<groupId>seleniumTest</groupId>
	<artifactId>seleniumTest</artifactId>
	<packaging>pom</packaging>
	<name>SeleniumTest</name>
	<version>3.2.2.CR2</version>
	<url>http://maven.apache.org</url>
	<properties>
		<http.port>8085</http.port>
	</properties>
	<repositories>
		<repository>
			<id>openqa</id>
			<name>OpenQA Repository</name>
			<url>http://archiva.openqa.org/repository/releases</url>
			<layout>default</layout>
			<snapshots>
				<enabled>false</enabled>
			</snapshots>
			<releases>
				<enabled>true</enabled>
			</releases>
		</repository>
		<repository>
			<id>openqa-snapshots</id>
			<name>OpenQA Snapshots Repository</name>
			<url>http://archiva.openqa.org/repository/snapshots</url>
			<layout>default</layout>
			<snapshots>
				<enabled>true</enabled>
			</snapshots>
			<releases>
				<enabled>false</enabled>
			</releases>
		</repository>
	</repositories>
	<build>
		<plugins>
			<plugin>
				<groupId>org.codehaus.cargo</groupId>
				<artifactId>cargo-maven2-plugin</artifactId>
				<version>0.3.1</version>
				<dependencies></dependencies>
				<configuration>
					<wait>false</wait>
					<container>
						<containerId>jetty6x</containerId>
						<dependencies>
							<dependency>
								<groupId>javax.el</groupId>
								<artifactId>el-api</artifactId>
							</dependency>
							<dependency>
								<groupId>el-impl</groupId>
								<artifactId>el-impl</artifactId>
							</dependency>
						</dependencies>
						<type>embedded</type>
					</container>
					<configuration>
						<properties>
							<cargo.servlet.port>
								${http.port}
							</cargo.servlet.port>
						</properties>
					</configuration>
				</configuration>
				<executions>
					<execution>
						<id>start-container</id>
						<phase>pre-integration-test</phase>
						<goals>
							<goal>start</goal>
						</goals>
					</execution>
					<execution>
						<id>stop-container</id>
						<phase>post-integration-test</phase>
						<goals>
							<goal>stop</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
		</plugins>
	</build>
	<profiles>
		<profile>
			<id>linux</id>
			<activation>
				<os>
					<family>unix</family>
				</os>
			</activation>
			<build>
				<plugins>
					<plugin>
						<groupId>org.codehaus.mojo</groupId>
						<artifactId>selenium-maven-plugin</artifactId>
						<version>1.0-beta-2</version>
						<executions>
							<execution>
								<id>xvfb</id>
								<phase>pre-integration-test</phase>
								<goals>
									<goal>xvfb</goal>
								</goals>
							</execution>
							
							<execution>
								<phase>pre-integration-test</phase>
								<goals>
									<goal>start-server</goal>
								</goals>
								<configuration>
									<background>true</background>
									<debug>false</debug>
								</configuration>
							</execution>
						</executions>
					</plugin>
				</plugins>
				<testResources>
					<testResource>
						<directory>src/test/testng/unix</directory>
						<targetPath>testng</targetPath>
						<filtering>true</filtering>
					</testResource>
				</testResources>
			</build>
		</profile>
		<profile>
			<id>windows</id>
			<activation>
				<os>
					<family>windows</family>
				</os>
			</activation>
			<build>
				<plugins>
					<plugin>
						<groupId>org.codehaus.mojo</groupId>
						<artifactId>selenium-maven-plugin</artifactId>
						<version>1.0-beta-2</version>
						<executions>
						<!-- 
							<execution>
								<phase>pre-integration-test</phase>
								<goals>
									<goal>start-server</goal>
								</goals>
								<configuration>
									<background>true</background>
									<debug>false</debug>
								</configuration>
							</execution>
							 -->
						</executions>
					</plugin>
				</plugins>
				<testResources>
					<testResource>
						<directory>src/test/testng/win</directory>
						<targetPath>testng</targetPath>
						<filtering>true</filtering>
					</testResource>
				</testResources>
			</build>
		</profile>
	</profiles>
	<modules>
		<module>richfaces</module>
		<module>samples</module>
	</modules>
	<dependencies>
		<dependency>
			<groupId>org.testng</groupId>
			<artifactId>testng</artifactId>
			<version>5.8</version>
			<scope>test</scope>
			<type>pom</type>
		</dependency>
		<dependency>
			<groupId>org.testng</groupId>
			<artifactId>testng</artifactId>
			<version>5.8</version>
			<scope>test</scope>
			<classifier>jdk15</classifier>
		</dependency>
		<dependency>
			<groupId>org.openqa.selenium.client-drivers</groupId>
			<artifactId>selenium-java-client-driver</artifactId>
			<version>1.0-SNAPSHOT</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.openqa.selenium.server</groupId>
			<artifactId>selenium-server-coreless</artifactId>
			<version>1.0-SNAPSHOT</version>
			<scope>test</scope>
			<exclusions>
				<exclusion>
					<groupId>jetty</groupId>
					<artifactId>org.mortbay.jetty</artifactId>
				</exclusion>
			</exclusions>
		</dependency>
		<dependency>
			<groupId>org.richfaces.ui</groupId>
			<artifactId>richfaces-ui</artifactId>
			<version>3.2.2.CR2</version>
		</dependency>
		<dependency>
			<groupId>javax.faces</groupId>
			<artifactId>jsf-impl</artifactId>
			<version>1.2_09</version>
		</dependency>
	</dependencies>
</project>