]> git-server-git.apps.pok.os.sepia.ceph.com Git - s3-tests.git/commitdiff
skip bucket location test if no api_name is configured 271/head
authorCasey Bodley <cbodley@redhat.com>
Fri, 5 Apr 2019 21:08:59 +0000 (17:08 -0400)
committerCasey Bodley <cbodley@redhat.com>
Fri, 5 Apr 2019 21:08:59 +0000 (17:08 -0400)
Signed-off-by: Casey Bodley <cbodley@redhat.com>
s3tests_boto3/functional/test_s3.py

index f85b5e1579609c74990e1942b587642fac0b4f1a..d38030f64dd744f32a0ada421c29bc905dfc79e3 100644 (file)
@@ -3419,10 +3419,12 @@ def test_bucket_create_exists():
 @attr(method='get')
 @attr(operation='get location')
 def test_bucket_get_location():
+    location_constraint = get_main_api_name()
+    if not location_constraint
+        raise SkipTest
     bucket_name = get_new_bucket_name()
     client = get_client()
 
-    location_constraint = get_main_api_name()
     client.create_bucket(Bucket=bucket_name, CreateBucketConfiguration={'LocationConstraint': location_constraint})
 
     response = client.get_bucket_location(Bucket=bucket_name)