From: Yehuda Sadeh Date: Wed, 15 Feb 2012 20:45:31 +0000 (-0800) Subject: fix atomic_write test, don't resuse same key handle for read and write X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=4633fe4c124e7b44d2d490053363a785c066e905;p=s3-tests.git fix atomic_write test, don't resuse same key handle for read and write --- diff --git a/s3tests/functional/test_s3.py b/s3tests/functional/test_s3.py index 12550998..514885fb 100644 --- a/s3tests/functional/test_s3.py +++ b/s3tests/functional/test_s3.py @@ -2961,10 +2961,12 @@ def _test_atomic_write(file_size): # verify A's _verify_atomic_key_data(key, file_size, 'A') + read_key = bucket.get_key(objname) + # create file of B's # but try to verify the file before we finish writing all the B's fp_b = FakeWriteFile(file_size, 'B', - lambda: _verify_atomic_key_data(key, file_size) + lambda: _verify_atomic_key_data(read_key, file_size) ) key.set_contents_from_file(fp_b)