From d978adbf2d8ad0f4367aa6ba9f1448be1343d46e Mon Sep 17 00:00:00 2001 From: Andrew Gaul Date: Fri, 2 Jan 2015 19:28:21 -0800 Subject: [PATCH] Add test for aborting a bogus multi-part upload --- s3tests/functional/test_s3.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/s3tests/functional/test_s3.py b/s3tests/functional/test_s3.py index d243d2a..5544244 100644 --- a/s3tests/functional/test_s3.py +++ b/s3tests/functional/test_s3.py @@ -4437,6 +4437,14 @@ def test_abort_multipart_upload(): eq(obj_count, 0) eq(bytes_used, 0) +def test_abort_multipart_upload_not_found(): + bucket = get_new_bucket() + key="mymultipart" + e = assert_raises(boto.exception.S3ResponseError, bucket.cancel_multipart_upload, key, '1') + eq(e.status, 404) + eq(e.reason, 'Not Found') + eq(e.error_code, 'NoSuchUpload') + @attr(resource='object') @attr(method='put') @attr(operation='concurrent multi-part uploads')