<?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>
    <artifactId>jira-components</artifactId>
    <groupId>com.atlassian.jira</groupId>
    <version>5.2</version>
  </parent>
  <artifactId>jira-tests</artifactId>
  <name>Atlassian JIRA - Code - Unit Tests</name>

  <build>
    <plugins>
      <plugin>
        <artifactId>maven-surefire-plugin</artifactId>
	      <version>2.12</version>
        <configuration>
          <argLine>-Xmx1024m -XX:MaxPermSize=512m ${jira.test.runner.jvmargs}</argLine>
          <skip>${maven.test.unit.skip}</skip>
	        <systemProperties>
            <java.awt.headless>true</java.awt.headless>
          </systemProperties>
          <includes>
            <include>com/atlassian/**/Test*.java</include>
            <include>com/atlassianjelly/**/Test*.java</include>
            <include>com/atlassian/**/*Test.java</include>
          </includes>
        </configuration>
      </plugin>

    </plugins>
  </build>

	<profiles>
		<profile>
			<id>ajEnforcer</id>
			<activation>
				<property>
					<name>ajEnforcer</name>
				</property>
			</activation>
			<build>
				<plugins>
					<plugin>
						<artifactId>maven-surefire-plugin</artifactId>
						<version>2.12</version>
						<configuration>
							<additionalClasspathElements>
								<additionalClasspathElement>${basedir}/target/aspect/artifacts/jira-core.jar</additionalClasspathElement>
							</additionalClasspathElements>
							<classpathDependencyExcludes>
								<classpathDependencyExcludes>com.atlassian.jira:jira-core</classpathDependencyExcludes>
							</classpathDependencyExcludes>
						</configuration>
					</plugin>
					<plugin>
						<groupId>com.atlassian</groupId>
						<artifactId>aspectj-maven-plugin</artifactId>
						<version>1.3</version>
						<executions>
							<execution>
								<id>test-compile</id>
								<phase>test-compile</phase>
								<goals>
									<goal>weave-test-aspects</goal>
								</goals>
								<configuration>
									<aspectArtifacts>
										<aspectArtifact>
											<artifact>com.atlassian:one-source-of-truth</artifact>
										</aspectArtifact>
									</aspectArtifacts>
									<instrumentedArtifacts>
										<instrumentedArtifact>
											<artifact>com.atlassian.jira:jira-core</artifact>
											<as>jira-core.jar</as>
										</instrumentedArtifact>
									</instrumentedArtifacts>
								</configuration>
							</execution>
						</executions>
					</plugin>
				</plugins>
			</build>
			<dependencies>
				<dependency>
					<groupId>com.atlassian</groupId>
					<artifactId>one-source-of-truth</artifactId>
					<version>1.2</version>
				</dependency>
				<dependency>
					<groupId>org.aspectj</groupId>
					<artifactId>aspectjrt</artifactId>
					<version>1.6.7</version>
				</dependency>
				<dependency>
					<groupId>org.aspectj</groupId>
					<artifactId>aspectjtools</artifactId>
					<version>1.6.12</version>
				</dependency>
			</dependencies>
		</profile>
	</profiles>

  <dependencies>
    <dependency>
      <groupId>com.atlassian.jira</groupId>
      <artifactId>jira-core</artifactId>
      <optional>true</optional>
    </dependency>
    <dependency>
      <groupId>com.google.code.findbugs</groupId>
      <artifactId>annotations</artifactId>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>com.google.code.findbugs</groupId>
      <artifactId>jsr305</artifactId>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit-dep</artifactId>
    </dependency>
    <dependency>
      <groupId>org.mockito</groupId>
      <artifactId>mockito-all</artifactId>
    </dependency>
    <dependency>
      <groupId>org.hamcrest</groupId>
      <artifactId>hamcrest-core</artifactId>
    </dependency>
    <dependency>
      <groupId>org.hamcrest</groupId>
      <artifactId>hamcrest-library</artifactId>
    </dependency>
    <dependency>
      <groupId>org.easymock</groupId>
      <artifactId>easymock</artifactId>
    </dependency>
    <dependency>
      <groupId>cglib</groupId>
      <artifactId>cglib</artifactId>
    </dependency>
    <dependency>
      <groupId>org.easymock</groupId>
      <artifactId>easymockclassextension</artifactId>
    </dependency>
    <dependency>
      <groupId>org.objenesis</groupId>
      <artifactId>objenesis</artifactId>
      <version>1.2</version>
    </dependency>
    <dependency>
      <groupId>mockobjects</groupId>
      <artifactId>mockobjects-dev</artifactId>
      <version>JIRA311-DEV</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>mockobjects</groupId>
      <artifactId>mockobjects-jdk1.3</artifactId>
      <version>0.07</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>mockobjects</groupId>
      <artifactId>mockobjects-jdk1.3-j2ee1.3</artifactId>
      <version>0.07</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>mockobjects</groupId>
      <artifactId>alt-j1.3-j2ee1.3</artifactId>
      <version>0.07</version>
      <scope>test</scope>
    </dependency>
      <dependency>
      <groupId>org.powermock.modules</groupId>
      <artifactId>powermock-module-junit4</artifactId>
      <version>1.3.8</version>
      <scope>test</scope>
	  </dependency>
	  <dependency>
	     <groupId>org.powermock.api</groupId>
	     <artifactId>powermock-api-easymock</artifactId>
	     <version>1.3.8</version>
	  </dependency>
		<dependency>
	     <groupId>com.atlassian.inception</groupId>
	     <artifactId>inception</artifactId>
	     <version>1.3</version>
	  </dependency>
	  <dependency>
	      <groupId>com.atlassian.jira</groupId>
	      <artifactId>jira-languages</artifactId>
	      <classifier>en_US</classifier>
	      <version>${project.version}</version>
	      <scope>test</scope>
	  </dependency>
	     <dependency>
	         <groupId>javax.servlet</groupId>
	         <artifactId>jsp-api</artifactId>
	     </dependency>
  </dependencies>
</project>
