From 1d09fc73b631fe9e158318ef945650bfe86770a6 Mon Sep 17 00:00:00 2001 From: Yulia Kovshova Date: Fri, 7 Oct 2022 17:18:44 +0300 Subject: [PATCH] Fix https://github.com/nspcc-dev/neofs-s3-gw/issues/628 Signed-off-by: Yulia Kovshova --- .../testsuites/services/s3_gate/test_s3_gate.py | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/pytest_tests/testsuites/services/s3_gate/test_s3_gate.py b/pytest_tests/testsuites/services/s3_gate/test_s3_gate.py index 69c543c..2448bbe 100644 --- a/pytest_tests/testsuites/services/s3_gate/test_s3_gate.py +++ b/pytest_tests/testsuites/services/s3_gate/test_s3_gate.py @@ -79,17 +79,7 @@ class TestS3Gate(TestS3GateBase): bucket_2 = s3_gate_bucket.create_bucket_s3(self.s3_client) with allure.step("Check buckets are presented in the system"): - # We have an issue that sometimes bucket is not available in the list - # immediately after creation, so we take several attempts with sleep - # TODO: remove after https://github.com/nspcc-dev/neofs-s3-gw/issues/628 is fixed - buckets = [] - for attempt in range(8): - with allure.step(f"Loading buckets list (attempt #{attempt})"): - buckets = s3_gate_bucket.list_buckets_s3(self.s3_client) - if bucket_1 in buckets and bucket_2 in buckets: - break # If both buckets are in the list, stop attempts - with allure.step(f"Buckets were not in the list, waiting before retry"): - sleep(s3_gate_bucket.S3_SYNC_WAIT_TIME) + buckets = s3_gate_bucket.list_buckets_s3(self.s3_client) assert bucket_1 in buckets, f"Expected bucket {bucket_1} is in the list" assert bucket_2 in buckets, f"Expected bucket {bucket_2} is in the list"