MCPcopy Create free account
hub / github.com/celery/celery / test_run_worker

Function test_run_worker

t/integration/test_worker.py:17–29  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

15
16
17def test_run_worker():
18 with pytest.raises(subprocess.CalledProcessError) as exc_info:
19 subprocess.check_output(
20 ["celery", "--config", "t.integration.worker_config", "worker"],
21 stderr=subprocess.STDOUT)
22
23 called_process_error = exc_info.value
24 assert called_process_error.returncode == 1, called_process_error
25 output = called_process_error.output.decode('utf-8')
26 assert output.find(
27 "Retrying to establish a connection to the message broker after a connection "
28 "loss has been disabled (app.conf.broker_connection_retry_on_startup=False). "
29 "Shutting down...") != -1, output
30
31
32def test_django_fixup_direct_worker(caplog, monkeypatch):

Callers

nothing calls this directly

Calls 3

raisesMethod · 0.80
findMethod · 0.80
decodeMethod · 0.45

Tested by

no test coverage detected