Skip to content

Commit

Permalink
Bump procedure compiler test utils
Browse files Browse the repository at this point in the history
- Bump version of compile-testing to be able to compile with java 9.
- In DuplicationAwareBaseProcessor change source version to be
     SourceVersion.latestSupported() instead of SourceVersion.RELEASE_8
- Update BadRecord age type to be long instead of int.
  Because of https://bugs.openjdk.java.net/browse/JDK-8066843 incorrect
  type of age field in BadRecord was not notices before.
  • Loading branch information
MishaDemianenko committed Nov 22, 2017
1 parent e8c031f commit aff58c8
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 8 deletions.
2 changes: 0 additions & 2 deletions community/procedure-compiler/processor/pom.xml
Expand Up @@ -97,8 +97,6 @@
<dependency>
<groupId>com.google.testing.compile</groupId>
<artifactId>compile-testing</artifactId>
<version>0.10</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.assertj</groupId>
Expand Down
Expand Up @@ -111,7 +111,7 @@ public Set<String> getSupportedAnnotationTypes()
@Override
public SourceVersion getSupportedSourceVersion()
{
return SourceVersion.RELEASE_8;
return SourceVersion.latestSupported();
}

@Override
Expand Down
Expand Up @@ -22,11 +22,11 @@
public class BadRecord
{

private static final int DEFAULT_AGE = 42;
private static final long DEFAULT_AGE = 42L;
private final String label; /* nonstatic fields should be public */
private final int age;
private final long age;

public BadRecord( String label, int age )
public BadRecord( String label, long age )
{
this.label = label;
this.age = age < 0 ? DEFAULT_AGE : age;
Expand Down
2 changes: 0 additions & 2 deletions enterprise/procedure-compiler-enterprise-tests/pom.xml
Expand Up @@ -57,8 +57,6 @@
<dependency>
<groupId>com.google.testing.compile</groupId>
<artifactId>compile-testing</artifactId>
<version>0.9</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
Expand Down
6 changes: 6 additions & 0 deletions pom.xml
Expand Up @@ -1157,6 +1157,12 @@
<version>${findbugs.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.google.testing.compile</groupId>
<artifactId>compile-testing</artifactId>
<version>0.13</version>
<scope>test</scope>
</dependency>
</dependencies>
</dependencyManagement>
</project>

0 comments on commit aff58c8

Please sign in to comment.