From 5f406d88ea5cc301811daaeef1136efe1ca73437 Mon Sep 17 00:00:00 2001 From: kshitijk4poor <82637225+kshitijk4poor@users.noreply.github.com> Date: Sun, 6 Sep 2026 17:17:57 +0000 Subject: [PATCH] test(cron): the run_job FakeFuture double answers done() like the real Future run_job's finally now asks the worker Future whether it is still running before deciding who tears the session down; the heartbeat test's stand-in future lacked done(). --- tests/cron/test_scheduler.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/cron/test_scheduler.py b/tests/cron/test_scheduler.py index 21759419d3..6abd13b40e 100644 --- a/tests/cron/test_scheduler.py +++ b/tests/cron/test_scheduler.py @@ -921,6 +921,9 @@ class TestRunJobSessionPersistence: def result(self): return {"final_response": "ok"} + def done(self): + return True # run_job's finally asks the real Future; this one has already returned + fake_future = FakeFuture() fake_pool = MagicMock() fake_pool.submit.return_value = fake_future