From ae94e349ac7a92a4b99262f92f18acfa0bf830b5 Mon Sep 17 00:00:00 2001 From: kshitijk4poor <82637225+kshitijk4poor@users.noreply.github.com> Date: Wed, 9 Sep 2026 11:14:45 +0530 Subject: [PATCH] test(state): mark the checkpoint-guard tests linux_only instead of a bare skipif AGENTS.md: a bare skipif(sys.platform != linux) is never listed by scripts/ci/list_os_marked_tests.py, so the tests would run nowhere on the OS lanes. The marker is the contract. --- .../test_deleted_wal_checkpoint_guard.py | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) diff --git a/tests/hermes_state/test_deleted_wal_checkpoint_guard.py b/tests/hermes_state/test_deleted_wal_checkpoint_guard.py index 8854b2a248..a5748fd62a 100644 --- a/tests/hermes_state/test_deleted_wal_checkpoint_guard.py +++ b/tests/hermes_state/test_deleted_wal_checkpoint_guard.py @@ -60,10 +60,7 @@ def _unlink_sidecars(db_path: Path) -> None: os.unlink(sidecar) -@pytest.mark.skipif( - not sys.platform.startswith("linux"), - reason="deleted-WAL write halt uses Linux unlink semantics", -) +@pytest.mark.linux_only # deleted-WAL write halt uses Linux unlink semantics def test_close_after_halt_runs_no_checkpoint(tmp_path, force_wal): """A writer halted by DeletedWalGenerationError must not checkpoint on close().""" path = tmp_path / "state.db" @@ -89,10 +86,7 @@ def test_close_after_halt_runs_no_checkpoint(tmp_path, force_wal): ) -@pytest.mark.skipif( - not sys.platform.startswith("linux"), - reason="deleted-WAL write halt uses Linux unlink semantics", -) +@pytest.mark.linux_only # deleted-WAL write halt uses Linux unlink semantics def test_halt_disables_close_time_checkpoint(tmp_path, force_wal): """On 3.12+ the halt must also call _disable_close_time_checkpoint().""" import sqlite3 @@ -127,10 +121,7 @@ def test_halt_disables_close_time_checkpoint(tmp_path, force_wal): db.close() -@pytest.mark.skipif( - not sys.platform.startswith("linux"), - reason="deleted-WAL write halt uses Linux unlink semantics", -) +@pytest.mark.linux_only # deleted-WAL write halt uses Linux unlink semantics def test_try_wal_checkpoint_skips_when_generation_lost(tmp_path, force_wal): """The periodic _try_wal_checkpoint() must skip when _db_wal_generation_lost is set.""" path = tmp_path / "state.db"