From 7757e8fe84f04312827652b79ba7fe4306a24e89 Mon Sep 17 00:00:00 2001 From: Matt Benjamin Date: Mon, 18 Mar 2019 02:21:09 -0400 Subject: [PATCH] boto{2,3}: rm functional.test_s3.test_lifecycle_rules_conflict The assumption that there may be only one rule per prefix has been removed. The rules specifically tested here--without tag filters--do overlap but are not in conflict. I am proposing to remove altogether rather than writing new deconfliction logic. Signed-off-by: Matt Benjamin --- s3tests_boto3/functional/test_s3.py | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/s3tests_boto3/functional/test_s3.py b/s3tests_boto3/functional/test_s3.py index f85b5e1..784704c 100644 --- a/s3tests_boto3/functional/test_s3.py +++ b/s3tests_boto3/functional/test_s3.py @@ -7930,24 +7930,6 @@ def test_lifecycle_invalid_status(): eq(status, 400) eq(error_code, 'MalformedXML') -@attr(resource='bucket') -@attr(method='put') -@attr(operation='rules conflicted in lifecycle') -@attr('lifecycle') -@attr(assertion='fails 400') -def test_lifecycle_rules_conflicted(): - bucket_name = get_new_bucket() - client = get_client() - rules=[{'ID': 'rule1', 'Expiration': {'Days': 2}, 'Prefix': 'test1/', 'Status':'Enabled'}, - {'ID': 'rule2', 'Expiration': {'Days': 3}, 'Prefix': 'test3/', 'Status':'Enabled'}, - {'ID': 'rule3', 'Expiration': {'Days': 5}, 'Prefix': 'test1/abc', 'Status':'Enabled'}] - lifecycle = {'Rules': rules} - - e = assert_raises(ClientError, client.put_bucket_lifecycle_configuration, Bucket=bucket_name, LifecycleConfiguration=lifecycle) - status, error_code = _get_status_and_error_code(e.response) - eq(status, 400) - eq(error_code, 'InvalidRequest') - @attr(resource='bucket') @attr(method='put') @attr(operation='set lifecycle config with expiration date')