diff --git a/tools/re-capture/check_refuted.py b/tools/re-capture/check_refuted.py index 51568964..8b1bf09f 100755 --- a/tools/re-capture/check_refuted.py +++ b/tools/re-capture/check_refuted.py @@ -75,13 +75,27 @@ if "--selftest" in sys.argv: f"~~{CLAIM}~~ was refuted on 2026-01-01.\n", 0), ("EMPTY REGISTER — must refuse, not pass", "no quoted claims at all\n", f"A live assertion: {CLAIM}.\n", 2), + # sylpheed-port's point: a control that runs where the tool does not look + # proves nothing about the tool. Case 2 plants INSIDE the scanned root and + # demands exit 1; this plants the SAME text OUTSIDE it and demands exit 0. + # The pair asserts that the scan boundary is real, instead of leaving it + # to be reasoned about. + ("plant OUTSIDE the scanned root — tool must not see it", REG, None, 0), ] bad = 0 print("── check_refuted harness self-test ──", flush=True) with tempfile.TemporaryDirectory() as td: for name, refuted, other, want in cases: d = Path(td) / name.replace(" ", "_").replace(",", "") - _corpus(d, refuted, other) + if other is None: + # register inside the root, revival text deliberately outside it + (d / "re").mkdir(parents=True, exist_ok=True) + (d / "re" / "REFUTED.md").write_text(refuted) + out = Path(td) / (d.name + "_elsewhere") + out.mkdir(exist_ok=True) + (out / "other.md").write_text(f"A live assertion: {CLAIM}.\n") + else: + _corpus(d, refuted, other) env = dict(os.environ, CHECK_REFUTED_ROOT=str(d)) r = subprocess.run([sys.executable, __file__], env=env, capture_output=True, text=True)