Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Update tests/deployments/test_steps.py
Browse files Browse the repository at this point in the history
Co-authored-by: Chris Guidry <[email protected]>
  • Loading branch information
kevingrismore and chrisguidry authored Jan 19, 2024
1 parent 5315709 commit e7d0d3c
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion tests/deployments/test_steps.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,15 @@
from prefect_aws import AwsCredentials
from prefect_aws.deployments.steps import get_s3_client, pull_from_s3, push_to_s3

os.environ["MOTO_S3_CUSTOM_ENDPOINTS"] = "http://custom.minio.endpoint:9000"

@pytest.fixture(scope="module", autouse=True)
def set_custom_endpoint():
original = os.environ.get("MOTO_S3_CUSTOM_ENDPOINTS")
os.environ["MOTO_S3_CUSTOM_ENDPOINTS"] = "http://custom.minio.endpoint:9000"
yield
os.environ.pop("MOTO_S3_CUSTOM_ENDPOINTS")
if original is not None:
os.environ["MOTO_S3_CUSTOM_ENDPOINTS"] = original


@pytest.fixture
Expand Down

0 comments on commit e7d0d3c

Please sign in to comment.