From aca962dac24fef0cedb2b44b6f7c29e8fab97c7e Mon Sep 17 00:00:00 2001 From: Colin Patrick McCabe Date: Wed, 4 May 2011 12:18:27 -0700 Subject: [PATCH] test_s3: add test_object_set_valid_acl Signed-off-by: Colin McCabe --- test_s3.py | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/test_s3.py b/test_s3.py index 6391f98..d606fa7 100644 --- a/test_s3.py +++ b/test_s3.py @@ -732,3 +732,27 @@ def test_access_bucket_publicreadwrite_object_publicreadwrite(): obj.b2.set_contents_from_string('baroverwrite') eq(get_bucket_key_names(obj.bucket2), frozenset(['foo', 'bar'])) obj.new.set_contents_from_string('newcontent') + +def test_object_set_valid_acl(): + XML_1 = "\ +\n\ + \n\ + bar\n\ + \n\ + \n\ + \n\ + \n\ + \n\ + " + config.main.user_id + "\n\ + \n\ + \n\ + FULL_CONTROL\n\ + \n\ + \n\ +\n\ +""" + bucket = get_new_bucket() + key = bucket.new_key('foo') + key.set_contents_from_string('bar') + key.set_xml_acl(XML_1)