Fixing Maven build for gRPC Java.

-------------
Created by MOE: http://code.google.com/p/moe-java
MOE_MIGRATED_REVID=81456318
This commit is contained in:
nathanmittler 2014-12-05 15:12:53 -08:00 committed by Eric Anderson
parent 56e307fcb6
commit 70341df582
4 changed files with 46 additions and 10 deletions

View File

@ -213,6 +213,24 @@
<locale>en_US</locale>
</configuration>
</plugin>
<!-- Skip the sniffer plugin. -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>animal-sniffer-maven-plugin</artifactId>
<executions>
<execution>
<id>check-java-version</id>
<phase>verify</phase>
<goals>
<goal>check</goal>
</goals>
<configuration>
<skip>true</skip>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>

View File

@ -487,8 +487,8 @@ public abstract class AbstractTransportTest {
fixedHeaders.put(METADATA_KEY, contextValue);
stub = MetadataUtils.attachHeaders(stub, fixedHeaders);
// .. and expect it to be echoed back in trailers
AtomicReference<Metadata.Trailers> trailersCapture = new AtomicReference<>();
AtomicReference<Metadata.Headers> headersCapture = new AtomicReference<>();
AtomicReference<Metadata.Trailers> trailersCapture = new AtomicReference<Metadata.Trailers>();
AtomicReference<Metadata.Headers> headersCapture = new AtomicReference<Metadata.Headers>();
stub = MetadataUtils.captureMetadata(stub, headersCapture, trailersCapture);
Assert.assertNotNull(stub.unaryCall(unaryRequest()));
@ -513,8 +513,8 @@ public abstract class AbstractTransportTest {
fixedHeaders.put(METADATA_KEY, contextValue);
stub = MetadataUtils.attachHeaders(stub, fixedHeaders);
// .. and expect it to be echoed back in trailers
AtomicReference<Metadata.Trailers> trailersCapture = new AtomicReference<>();
AtomicReference<Metadata.Headers> headersCapture = new AtomicReference<>();
AtomicReference<Metadata.Trailers> trailersCapture = new AtomicReference<Metadata.Trailers>();
AtomicReference<Metadata.Headers> headersCapture = new AtomicReference<Metadata.Headers>();
stub = MetadataUtils.captureMetadata(stub, headersCapture, trailersCapture);
List<Integer> responseSizes = Arrays.asList(50, 100, 150, 200);
@ -564,7 +564,7 @@ public abstract class AbstractTransportTest {
protected static void assertSuccess(StreamRecorder<?> recorder) {
if (recorder.getError() != null) {
throw new AssertionError("Error in stream", recorder.getError());
throw new AssertionError(recorder.getError());
}
}
}

View File

@ -86,11 +86,7 @@ public class Util {
Assert.assertEquals(expected, actual);
} else {
for (int i = 0; i < expected.size(); i++) {
try {
assertEquals(expected.get(i), actual.get(i));
} catch (Error e) {
throw new AssertionError("At index " + i, e);
}
assertEquals(expected.get(i), actual.get(i));
}
}
}

View File

@ -52,4 +52,26 @@
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<!-- Skip the sniffer plugin for Netty. -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>animal-sniffer-maven-plugin</artifactId>
<executions>
<execution>
<id>check-java-version</id>
<phase>verify</phase>
<goals>
<goal>check</goal>
</goals>
<configuration>
<skip>true</skip>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>