(self)
| 25 | x.stop() |
| 26 | |
| 27 | def test_on_stop(self): |
| 28 | from celery.concurrency import thread |
| 29 | x = thread.TaskPool() |
| 30 | x.on_stop() |
| 31 | with pytest.raises(RuntimeError): |
| 32 | x.on_apply(operator.add, (2, 2), {}, noop, noop) |
| 33 | |
| 34 | def test_on_stop_cancels_pending_futures(self): |
| 35 | import threading |