]> git-server-git.apps.pok.os.sepia.ceph.com Git - s3-tests.git/commitdiff
test_s3: extend multipart test
authorYehuda Sadeh <yehuda@inktank.com>
Tue, 1 Apr 2014 19:20:16 +0000 (12:20 -0700)
committerYehuda Sadeh <yehuda@inktank.com>
Tue, 1 Apr 2014 19:24:53 +0000 (12:24 -0700)
Make test use a multipart upload with different part sizes, to exercise
code that triggered #7935.

Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
s3tests/functional/test_s3.py

index 464fbe1ed00048f0c6c77d0f23876ea6c64f4515..fb77718744646e7f03bc5c370b4cdea4ea814dd0 100644 (file)
@@ -4132,10 +4132,13 @@ def test_multipart_upload_contents():
     for i in range(0, num_parts):
         mp.upload_part_from_file(StringIO(payload), i+1)
 
+    last_payload='123'*1024*1024
+    mp.upload_part_from_file(StringIO(last_payload), 4)
+
     mp.complete_upload()
     key=bucket.get_key(key_name)
     test_string=key.get_contents_as_string()
-    assert test_string == payload*num_parts
+    assert test_string == payload*num_parts+last_payload
 
 
 @attr(resource='object')