diff --git a/tests/conftest.py b/tests/conftest.py index 95422dd6a8..97958561d0 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -669,7 +669,10 @@ def s3_url(s3, s3_scratch, test_name_uuid): try: yield url finally: - s3.rm(url, recursive=True) + try: + s3.rm(url, recursive=True) + except FileNotFoundError: + pass GCS_REGION = "us-central1" @@ -698,7 +701,10 @@ def gcs_url(gcs, gcs_scratch, test_name_uuid): try: yield url finally: - gcs.rm(url, recursive=True) + try: + gcs.rm(url, recursive=True) + except FileNotFoundError: + pass @pytest.fixture(scope="session") @@ -724,7 +730,10 @@ def az_url(az, az_scratch, test_name_uuid): try: yield url finally: - az.rm(url, recursive=True) + try: + az.rm(url, recursive=True) + except FileNotFoundError: + pass # this code was taken from pytest docs