mirror of
https://github.com/zulip/zulip.git
synced 2025-11-01 20:44:04 +00:00
queue: Do test retries in tests.
The lambda passed to `queue_json_publish` is used if
`settings.USING_RABBITMQ` is unset -- which is only true in tests. As
such, this pattern causes failures to never actually retry within
tests.
This behaviour has existed ever since the outgoing webhook code was
introduced in 53a8b2ac87, with no explanation. Not passing that
argument allows tests to verify the retry behaviour when webhooks
fail.
This commit is contained in:
committed by
Tim Abbott
parent
7dbd98d25c
commit
eb7a2f2c38
@@ -437,4 +437,4 @@ def retry_event(
|
||||
if event["failed_tries"] > MAX_REQUEST_RETRIES:
|
||||
failure_processor(event)
|
||||
else:
|
||||
queue_json_publish(queue_name, event, lambda x: None)
|
||||
queue_json_publish(queue_name, event)
|
||||
|
||||
Reference in New Issue
Block a user