(self, manager, subtests)
| 707 | redis_connection.delete(redis_key) |
| 708 | |
| 709 | def test_chain_children_with_errbacks(self, manager, subtests): |
| 710 | if not manager.app.conf.result_backend.startswith("redis"): |
| 711 | raise pytest.skip("Requires redis result backend.") |
| 712 | redis_connection = get_redis_connection() |
| 713 | |
| 714 | redis_key = str(uuid.uuid4()) |
| 715 | errback = redis_count.si(redis_key=redis_key) |
| 716 | |
| 717 | child_task_count = 42 |
| 718 | child_sig = fail.si() |
| 719 | child_sig.link_error(errback) |
| 720 | chain_sig = chain(child_sig for _ in range(child_task_count)) |
| 721 | |
| 722 | redis_connection.delete(redis_key) |
| 723 | with subtests.test(msg="Chain fails due to a child task dying"): |
| 724 | res_obj = chain_sig() |
| 725 | with pytest.raises(ExpectedException): |
| 726 | res_obj.get(timeout=TIMEOUT) |
| 727 | with subtests.test(msg="Chain child task errbacks are called"): |
| 728 | # Only the first child task gets a change to run and fail |
| 729 | await_redis_count(1, redis_key=redis_key) |
| 730 | redis_connection.delete(redis_key) |
| 731 | |
| 732 | def test_chain_with_callback_child_replaced(self, manager, subtests): |
| 733 | if not manager.app.conf.result_backend.startswith("redis"): |
nothing calls this directly
no test coverage detected