]> git-server-git.apps.pok.os.sepia.ceph.com Git - s3-tests.git/commitdiff
crypto: add key headers to valid HEAD requests 154/head
authorCasey Bodley <cbodley@redhat.com>
Tue, 28 Feb 2017 21:58:17 +0000 (16:58 -0500)
committerCasey Bodley <cbodley@redhat.com>
Tue, 28 Mar 2017 14:03:59 +0000 (10:03 -0400)
Signed-off-by: Casey Bodley <cbodley@redhat.com>
s3tests/functional/test_s3.py

index a6ed33ca5ddbfb17e87225e8a76ccfdf39a7c140..8f9119d8ed6022e834f20d1262f8c059b8db01fa 100644 (file)
@@ -7786,7 +7786,7 @@ def test_encryption_sse_c_multipart_upload():
     eq(result.get('x-rgw-object-count', 1), 1)
     eq(result.get('x-rgw-bytes-used', 30 * 1024 * 1024), 30 * 1024 * 1024)
 
-    k = bucket.get_key(key)
+    k = bucket.get_key(key, headers=enc_headers)
     eq(k.metadata['foo'], 'bar')
     eq(k.content_type, content_type)
     test_string = k.get_contents_as_string(headers=enc_headers)
@@ -7885,7 +7885,7 @@ def test_encryption_sse_c_multipart_bad_download():
     eq(result.get('x-rgw-object-count', 1), 1)
     eq(result.get('x-rgw-bytes-used', 30 * 1024 * 1024), 30 * 1024 * 1024)
 
-    k = bucket.get_key(key)
+    k = bucket.get_key(key, headers=put_headers)
     eq(k.metadata['foo'], 'bar')
     eq(k.content_type, content_type)
     e = assert_raises(boto.exception.S3ResponseError,
@@ -7939,7 +7939,7 @@ def test_encryption_sse_c_post_object_authenticated_request():
         'x-amz-server-side-encryption-customer-key-md5': 'DWygnHRtgiJ77HCm+1rvHw=='
     }
 
-    key = bucket.get_key("foo.txt")
+    key = bucket.get_key("foo.txt", headers=get_headers)
     got = key.get_contents_as_string(headers=get_headers)
     eq(got, 'bar')