Skip to content

Commit

Permalink
Fix test with multiple destionations
Browse files Browse the repository at this point in the history
  • Loading branch information
sevdog committed Mar 14, 2024
1 parent ff36584 commit 30ff193
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion tests/test_celery_ping.py
Original file line number Diff line number Diff line change
Expand Up @@ -160,10 +160,18 @@ def test_check_status_reports_destinations(
{"celery2@4cc150a7b49b": CeleryPingHealthCheck.CORRECT_PING_RESPONSE},
{"celery3@4cc150a7b49b": CeleryPingHealthCheck.CORRECT_PING_RESPONSE},
],
), patch(
self.CELERY_APP_CONTROL_INSPECT_ACTIVE_QUEUES,
return_value={
celery_worker: [
{"name": queue.name} for queue in settings.CELERY_QUEUES
]
for celery_worker in ("celery1@4cc150a7b49b", "celery2@4cc150a7b49b", "celery3@4cc150a7b49b")
},
):
health_check.check_status()

assert len(health_check.errors) == 1
assert not health_check.errors


class TestCeleryPingHealthCheckApps:
Expand Down

0 comments on commit 30ff193

Please sign in to comment.