You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jclouds.apache.org by an...@apache.org on 2013/10/18 01:11:53 UTC

git commit: Move Expect: 100 stripping after asserts against the request

Updated Branches:
  refs/heads/move-expect-strip [created] fb385c6c8


Move Expect: 100 stripping after asserts against the request

Follow-up to e30f86521


Project: http://git-wip-us.apache.org/repos/asf/incubator-jclouds/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-jclouds/commit/fb385c6c
Tree: http://git-wip-us.apache.org/repos/asf/incubator-jclouds/tree/fb385c6c
Diff: http://git-wip-us.apache.org/repos/asf/incubator-jclouds/diff/fb385c6c

Branch: refs/heads/move-expect-strip
Commit: fb385c6c880537dc17ce47c6f1b8246383bcf5c1
Parents: 13f38d6
Author: Andrew Phillips <an...@apache.org>
Authored: Thu Oct 17 19:09:36 2013 -0400
Committer: Andrew Phillips <an...@apache.org>
Committed: Thu Oct 17 19:09:36 2013 -0400

----------------------------------------------------------------------
 .../integration/internal/BaseBlobSignerLiveTest.java         | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-jclouds/blob/fb385c6c/blobstore/src/test/java/org/jclouds/blobstore/integration/internal/BaseBlobSignerLiveTest.java
----------------------------------------------------------------------
diff --git a/blobstore/src/test/java/org/jclouds/blobstore/integration/internal/BaseBlobSignerLiveTest.java b/blobstore/src/test/java/org/jclouds/blobstore/integration/internal/BaseBlobSignerLiveTest.java
index 879f8f9..fe36475 100644
--- a/blobstore/src/test/java/org/jclouds/blobstore/integration/internal/BaseBlobSignerLiveTest.java
+++ b/blobstore/src/test/java/org/jclouds/blobstore/integration/internal/BaseBlobSignerLiveTest.java
@@ -131,12 +131,12 @@ public class BaseBlobSignerLiveTest extends BaseBlobStoreIntegrationTest {
       String container = getContainerName();
       try {
          HttpRequest request = view.getSigner().signPutBlob(container, blob, 3 /* seconds */);
-         // Strip Expect: 100-continue since Java 7+ will throw a
-         // ProtocolException instead of setting the response code:
-         // http://www.docjar.com/html/api/sun/net/www/protocol/http/HttpURLConnection.java.html#1021
-         request = request.toBuilder().removeHeader(EXPECT).build();
          assertEquals(request.getFilters().size(), 0);
 
+         // Strip Expect: 100-continue to make actual responses visible, since 
+         // Java 7+ will throw a ProtocolException instead of setting the response code:
+         // http://www.docjar.com/html/api/sun/net/www/protocol/http/HttpURLConnection.java.html#1021
+         request = request.toBuilder().removeHeader(EXPECT).build();
          Strings2.toString(view.utils().http().invoke(request).getPayload());
          assertConsistencyAwareContainerSize(container, 1);