def test_s3_copy_md5(self):
    bucket_name = ('test-bucket-%s' % short_uid())
    client = self._get_test_client()
    client.create_bucket(Bucket=bucket_name)
    src_key = 'src'
    client.put_object(Bucket=bucket_name, Key=src_key, Body='something')
    dest_key = 'dest'
    response = client.copy_object(Bucket=bucket_name, CopySource={'Bucket': bucket_name, 'Key': src_key}, Key=dest_key)
    self.assertEqual(response['ResponseMetadata']['HTTPStatusCode'], 200)
    dest_key2 = 'dest'
    url = client.generate_presigned_url('copy_object', Params={'Bucket': bucket_name, 'CopySource': {'Bucket': bucket_name, 'Key': src_key}, 'Key': dest_key2})
    request_response = requests.put(url, verify=False)
    self.assertEqual(request_response.status_code, 200)
    self._delete_bucket(bucket_name, [src_key, dest_key, dest_key2])
def test_s3_copy_md5(self):
    bucket_name = ('test-bucket-%s' % short_uid())
    client = self._get_test_client()
    client.create_bucket(Bucket=bucket_name)
    src_key = 'src'
    client.put_object(Bucket=bucket_name, Key=src_key, Body='something')
    dest_key = 'dest'
    response = client.copy_object(Bucket=bucket_name, CopySource={'Bucket': bucket_name, 'Key': src_key}, Key=dest_key)
    self.assertEqual(response['ResponseMetadata']['HTTPStatusCode'], 200)
    dest_key2 = 'dest'
    url = client.generate_presigned_url('copy_object', Params={'Bucket': bucket_name, 'CopySource': {'Bucket': bucket_name, 'Key': src_key}, 'Key': dest_key2})
    request_response = requests.put(url, verify=False)
    self.assertEqual(request_response.status_code, 200)
    self._delete_bucket(bucket_name, [src_key, dest_key, dest_key2])