s3: test_multipart_checksum_sha256 uses correct ChecksumSHA256 for second complete

the second complete is supposed to fail due to missing etag, so use the
correct value of ChecksumSHA256

Signed-off-by: Casey Bodley <cbodley@redhat.com>
This commit is contained in:
Casey Bodley 2024-10-09 09:25:30 -04:00
parent fc9db89f53
commit 64f178e7dc

View file

@ -13782,7 +13782,7 @@ def test_multipart_checksum_sha256():
assert error_code == 'InvalidRequest' assert error_code == 'InvalidRequest'
# should reject the missing part checksum # should reject the missing part checksum
e = assert_raises(ClientError, client.complete_multipart_upload, Bucket=bucket, Key=key, UploadId=upload_id, ChecksumSHA256='bad', MultipartUpload={'Parts': [ e = assert_raises(ClientError, client.complete_multipart_upload, Bucket=bucket, Key=key, UploadId=upload_id, ChecksumSHA256='SHA256', MultipartUpload={'Parts': [
{'ETag': response['ETag'].strip('"'), 'PartNumber': 1}]}) {'ETag': response['ETag'].strip('"'), 'PartNumber': 1}]})
status, error_code = _get_status_and_error_code(e.response) status, error_code = _get_status_and_error_code(e.response)
assert status == 400 assert status == 400