From 2a66c7f2eefc46d1aaa8eaa3fc090776802f4695 Mon Sep 17 00:00:00 2001 From: kshitijk4poor <82637225+kshitijk4poor@users.noreply.github.com> Date: Wed, 7 Oct 2026 17:13:00 +0530 Subject: [PATCH] test(cron): pin that the tick-lock probe names the lock file The tick-lock case only asserted probe_store() returned an error, which any other probe failure would also satisfy. Assert the error names .tick.lock so the case proves that branch fired. Gate r1 (PM12, quality) Low finding. --- tests/cron/test_due_scan_save_failure.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/cron/test_due_scan_save_failure.py b/tests/cron/test_due_scan_save_failure.py index f797f2eb5a..fe191e1dde 100644 --- a/tests/cron/test_due_scan_save_failure.py +++ b/tests/cron/test_due_scan_save_failure.py @@ -369,7 +369,7 @@ def test_unwritable_store_is_shown_in_cron_status_and_announced_once(cron_store, lock.write_text("") os.chmod(lock, 0o400) try: - assert store_health.probe_store(cron_dir) is not None + assert store_health.probe_store(cron_dir).filename == str(lock) finally: os.chmod(lock, 0o600)