[go: nahoru, domu]

Skip to content

Commit

Permalink
Fix broken snapshot and proto tests (#512)
Browse files Browse the repository at this point in the history
* fix snapshot tests

* ignore eclipse metadata

* reset some sample files

* fix prototest
  • Loading branch information
elharo authored and chingor13 committed Nov 6, 2018
1 parent 287cca1 commit 710117e
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,7 @@ target/
bin/
*.iml
.idea
.project
.settings
.classpath

2 changes: 1 addition & 1 deletion google-http-client-protobuf/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
<artifactId>maven-protoc-plugin</artifactId>
<version>0.4.2</version>
<configuration>
<protocArtifact>com.google.protobuf:protoc:${project.protobuf-java.version}-build2:exe:${os.detected.classifier}</protocArtifact>
<protocArtifact>com.google.protobuf:protoc:${project.protobuf-java.version}:exe:${os.detected.classifier}</protocArtifact>
</configuration>
<executions>
<execution>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -745,7 +745,8 @@ public LowLevelHttpRequest buildRequest(String method, String url) throws IOExce
assertEquals(ImmutableList.of("a2", "b2", "c2"), lowLevelRequest.getHeaderValues("objlist"));
assertEquals(ImmutableList.of("a1", "a2"), lowLevelRequest.getHeaderValues("r"));
assertTrue(lowLevelRequest.getHeaderValues("accept-encoding").isEmpty());
assertEquals(ImmutableList.of("foo " + HttpRequest.USER_AGENT_SUFFIX),
assertEquals(ImmutableList.of("foo Google-HTTP-Java-Client/"
+ HttpRequest.VERSION + " (gzip)"),
lowLevelRequest.getHeaderValues("user-agent"));
assertEquals(ImmutableList.of("b"), lowLevelRequest.getHeaderValues("a"));
assertEquals(ImmutableList.of("VALUE"), lowLevelRequest.getHeaderValues("value"));
Expand Down Expand Up @@ -984,7 +985,8 @@ public void testExecute_curlLogger() throws Exception {
if (message.startsWith("curl")) {
found = true;
assertEquals("curl -v --compressed -H 'Accept-Encoding: gzip' -H 'User-Agent: "
+ HttpRequest.USER_AGENT_SUFFIX + "' -- 'http://google.com/#q=a'\"'\"'b'\"'\"'c'",
+ "Google-HTTP-Java-Client/" + HttpRequest.VERSION + " (gzip)"
+ "' -- 'http://google.com/#q=a'\"'\"'b'\"'\"'c'",
message);
}
}
Expand Down

0 comments on commit 710117e

Please sign in to comment.