blob: 812cfaa1c99ebe360efe01945d7df3495173c3ef [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright 2013 Google LLC
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!-- TODO(gak): see if we can manage these dependencies any better -->
<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>
<parent>
<groupId>com.google.auto.value</groupId>
<artifactId>auto-value-parent</artifactId>
<version>HEAD-SNAPSHOT</version>
<relativePath>../../../pom.xml</relativePath>
</parent>
<url>https://github.com/google/auto/tree/master/value</url>
<groupId>com.google.auto.value.it.functional</groupId>
<artifactId>functional</artifactId>
<version>HEAD-SNAPSHOT</version>
<name>Auto-Value Functional Integration Test</name>
<properties>
<kotlin.version>1.5.31</kotlin.version>
<exclude.tests>this-matches-nothing</exclude.tests>
</properties>
<dependencies>
<dependency>
<groupId>com.google.auto.value</groupId>
<artifactId>auto-value-annotations</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>com.google.auto.value</groupId>
<artifactId>auto-value</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>com.google.auto.service</groupId>
<artifactId>auto-service</artifactId>
<version>1.0</version>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
</dependency>
<dependency>
<groupId>com.google.code.findbugs</groupId>
<artifactId>jsr305</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.google.gwt</groupId>
<artifactId>gwt-user</artifactId>
<version>2.9.0</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava-testlib</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.google.truth</groupId>
<artifactId>truth</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.google.truth.extensions</groupId>
<artifactId>truth-java8-extension</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.google.testing.compile</groupId>
<artifactId>compile-testing</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>dev.gradleplugins</groupId>
<artifactId>gradle-test-kit</artifactId>
<version>7.2</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<version>3.12.4</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.eclipse.jdt</groupId>
<artifactId>ecj</artifactId>
<version>3.25.0</version>
</dependency>
<dependency>
<groupId>com.google.escapevelocity</groupId>
<artifactId>escapevelocity</artifactId>
<version>0.9.1</version>
</dependency>
<dependency>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-stdlib</artifactId>
<version>${kotlin.version}</version>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>3.2.0</version>
</plugin>
<plugin>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-maven-plugin</artifactId>
<version>${kotlin.version}</version>
<executions>
<!--
The Kotlin configuration here is a bit unusual. JetBrains recommends
<https://kotlinlang.org/docs/maven.html#compile-kotlin-and-java-sources>
a fairly invasive reconfiguration of the maven-compiler-plugin (which compiles Java)
in order to ensure that the Kotlin compiler can run first. In our case, we have just
one Kotlin file that a test in Java accesses. So, even though it is in src/test/java,
we compile it in the `compile` goal, which means it is available to the Java test sources
when they are compiled in the `default-testCompile` goal.
Currently if you want to use JDK ≥ 16 then you must set
JAVA_TOOL_OPTIONS=__illegal-access=permit
except the two underscores should be dashes (which XML comments won't allow us to write).
This is a bug that will presumably be fixed in a forthcoming version.
-->
<execution>
<id>compile</id>
<goals>
<goal>compile</goal>
</goals>
<configuration>
<sourceDirs>
<sourceDir>${project.basedir}/src/test/java</sourceDir>
</sourceDirs>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.1</version>
<dependencies>
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-java</artifactId>
<version>1.1.0</version>
</dependency>
</dependencies>
<configuration>
<source>${java.specification.version}</source>
<target>${java.specification.version}</target>
<compilerArgs>
<arg>-Xlint:all</arg>
<arg>-encoding</arg>
<arg>utf8</arg>
<arg>-Acom.google.auto.value.AutoBuilderIsUnstable</arg>
</compilerArgs>
<showWarnings>true</showWarnings>
<showDeprecation>true</showDeprecation>
<testExcludes>
<exclude>${exclude.tests}</exclude>
</testExcludes>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-deploy-plugin</artifactId>
<version>2.8.2</version>
<configuration>
<!-- Build/test, but don't deploy -->
<skip>true</skip>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.22.2</version>
<configuration>
<argLine>${test.jvm.flags}</argLine>
<systemPropertyVariables>
<autoValueVersion>${project.version}</autoValueVersion>
</systemPropertyVariables>
</configuration>
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>eclipse</id>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.1</version>
<dependencies>
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-java</artifactId>
<version>1.1.0</version>
</dependency>
</dependencies>
<configuration>
<source>${java.specification.version}</source>
<target>${java.specification.version}</target>
<compilerArgs>
<arg>-Xlint:all</arg>
<arg>-encoding</arg>
<arg>utf8</arg>
</compilerArgs>
<showWarnings>true</showWarnings>
<showDeprecation>true</showDeprecation>
<testExcludes>
<exclude>${exclude.tests}</exclude>
</testExcludes>
</configuration>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>exclude-java8-tests</id>
<activation>
<jdk>(,1.7]</jdk>
</activation>
<properties>
<exclude.tests>**/AutoValueJava8Test.java</exclude.tests>
</properties>
</profile>
<profile>
<id>open-modules</id>
<activation>
<jdk>[9,)</jdk>
</activation>
<properties>
<test.jvm.flags>--add-opens=jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED</test.jvm.flags>
</properties>
</profile>
<profile>
<!-- Before JDK 11, parameter names from already-compiled classes are not reliably available
to the compiler even when they are present in class files. Since our Kotlin test file
obviously has to be compiled separately from the Java test that uses it,
AutoBuilderKotlinTest doesn't pass on earlier JDK versions. -->
<id>exclude-separate-compilation-parameter-names</id>
<activation>
<jdk>(,11)</jdk>
</activation>
<properties>
<exclude.tests>**/AutoBuilderKotlinTest.java</exclude.tests>
</properties>
</profile>
</profiles>
</project>