Skip to content

Commit 57a84c7

Browse files
committed
fix: add retry decorator to pytest fixture
1 parent 9a9b62d commit 57a84c7

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

tests/integration/feeds/test_feeds_client.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
from nisystemlink.clients.core import ApiException
1212
from nisystemlink.clients.feeds import FeedsClient
1313
from nisystemlink.clients.feeds.models import CreateFeedRequest, Platform
14+
from uplink import retry
1415

1516
FEED_DESCRIPTION = "Sample feed for uploading packages"
1617
PACKAGE_PATH = str(
@@ -22,6 +23,7 @@
2223

2324

2425
@pytest.fixture(scope="class")
26+
@retry(when=retry.when.status(429), stop=retry.stop.after_attempt(5))
2527
def client(enterprise_config) -> FeedsClient:
2628
"""Fixture to create a FeedsClient instance."""
2729
return FeedsClient(enterprise_config)

0 commit comments

Comments
 (0)