<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>

	<groupId>com.haddouti.pg</groupId>
	<artifactId>testapp-jee6</artifactId>
	<version>0.0.4-SNAPSHOT</version>
	<packaging>war</packaging>

	<name>testapp-jee6</name>

	<properties>
		<endorsed.dir>${project.build.directory}/endorsed</endorsed.dir>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

		<version.junit>4.8.1</version.junit>
		<version.arquillian>1.1.4.Final</version.arquillian>
	</properties>

	<dependencyManagement>
		<dependencies>
			<dependency>
				<groupId>junit</groupId>
				<artifactId>junit</artifactId>
				<version>${version.junit}</version>
				<scope>test</scope>
			</dependency>
			<dependency>
				<groupId>org.jboss.arquillian</groupId>
				<artifactId>arquillian-bom</artifactId>
				<version>${version.arquillian}</version>
				<scope>import</scope>
				<type>pom</type>
			</dependency>
		</dependencies>
	</dependencyManagement>


	<build>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-compiler-plugin</artifactId>
				<version>2.3.2</version>
				<configuration>
					<source>1.7</source>
					<target>1.7</target>
					<compilerArguments>
						<endorseddirs>${endorsed.dir}</endorseddirs>
					</compilerArguments>
				</configuration>
			</plugin>

			<!-- Updating the Surefire plugin to resolve a bug with clearing the context -->
			<plugin>
				<artifactId>maven-surefire-plugin</artifactId>
				<version>2.17</version>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-war-plugin</artifactId>
				<version>2.1.1</version>
				<configuration>
					<failOnMissingWebXml>false</failOnMissingWebXml>
				</configuration>
			</plugin>
		</plugins>
	</build>

	<profiles>
		<profile>
			<id>arquillian-weld-embedded</id>
			<dependencies>

				<!-- JEE Spec -->
				<dependency>
					<groupId>org.jboss.spec</groupId>
					<artifactId>jboss-javaee-6.0</artifactId>
					<version>1.0.0.Final</version>
					<type>pom</type>
					<scope>provided</scope>
				</dependency>

				<!-- Arquillian Container: Weld EE container -->
				<dependency>
					<groupId>org.jboss.arquillian.container</groupId>
					<artifactId>arquillian-weld-ee-embedded-1.1</artifactId>
					<version>1.0.0.CR3</version>
					<scope>test</scope>
				</dependency>
				<dependency>
					<groupId>org.jboss.weld</groupId>
					<artifactId>weld-core</artifactId>
					<version>1.1.5.Final</version>
					<scope>test</scope>
				</dependency>
				<dependency>
					<groupId>org.slf4j</groupId>
					<artifactId>slf4j-simple</artifactId>
					<version>1.6.4</version>
					<scope>test</scope>
				</dependency>
			</dependencies>
		</profile>
		<profile>
			<id>arquillian-glassfish-embedded</id>
			<dependencies>
				<!-- ArquillianContainer: Glassfish embedded -->
				<dependency>
					<groupId>org.jboss.arquillian.container</groupId>
					<artifactId>arquillian-glassfish-embedded-3.1</artifactId>
					<version>1.0.0.CR3</version>
					<scope>test</scope>
				</dependency>
				<dependency>
					<groupId>org.glassfish.main.extras</groupId>
					<artifactId>glassfish-embedded-all</artifactId>
					<version>3.1.2</version>
					<scope>provided</scope>
				</dependency>
			</dependencies>
		</profile>
		<profile>
			<id>arquillian-wildfly-embedded</id>

			<dependencies>
				<!-- JEE Spec -->
				<dependency>
					<groupId>org.jboss.spec</groupId>
					<artifactId>jboss-javaee-6.0</artifactId>
					<version>1.0.0.Final</version>
					<type>pom</type>
					<scope>provided</scope>
				</dependency>

				<!-- Arquillian Container: WildFly 8 Embedded 
				Pay attention, that this container expects an installed WildFly,
				referenced in the arquillian.xml
				-->
				<dependency>
					<groupId>org.wildfly</groupId>
					<artifactId>wildfly-arquillian-container-embedded</artifactId>
					<version>8.1.0.CR1</version>
					<scope>test</scope>
				</dependency>
				<dependency>
					<groupId>org.wildfly</groupId>
					<artifactId>wildfly-embedded</artifactId>
					<version>8.1.0.CR1</version>
					<scope>test</scope>
				</dependency>
			</dependencies>
		</profile>
	</profiles>

	<dependencies>

		<!-- Testing: JUnit, Arquillian -->
		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.jboss.arquillian.junit</groupId>
			<artifactId>arquillian-junit-container</artifactId>
			<scope>test</scope>
		</dependency>
	</dependencies>

</project>