Skip to content

Commit

Permalink
Increase retries for test clients
Browse files Browse the repository at this point in the history
Tests sometimes fail in pipelines if they run concurrently against the same system. To make this a bit more robust we increase retries.
  • Loading branch information
ahartel committed Jul 1, 2024
1 parent 29d67ec commit e429b36
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tests/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@ def sync_client() -> Client:
return Client(
token=get_env_var("TEST_TOKEN"),
host=get_env_var("TEST_API_URL"),
total_retries=4,
# This will retry after [0.0, 0.5, 1.0, 2.0, 4.0] seconds
total_retries=5,
)


Expand All @@ -20,7 +21,8 @@ async def async_client() -> AsyncIterable[AsyncClient]:
async with AsyncClient(
token=get_env_var("TEST_TOKEN"),
host=get_env_var("TEST_API_URL"),
total_retries=4,
# This will retry after [0.0, 0.5, 1.0, 2.0, 4.0] seconds
total_retries=5,
) as client:
yield client

Expand Down

0 comments on commit e429b36

Please sign in to comment.