From a536a81b0dc804f1184f201ea3a1c463f8371c79 Mon Sep 17 00:00:00 2001 From: iomgaa Date: Wed, 15 Jul 2026 10:07:19 -0400 Subject: [PATCH] chore: apply ruff format to dead-path guard test --- tests/unit/test_no_dead_perquestion_paths.py | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/tests/unit/test_no_dead_perquestion_paths.py b/tests/unit/test_no_dead_perquestion_paths.py index 82d3512..0270ec6 100644 --- a/tests/unit/test_no_dead_perquestion_paths.py +++ b/tests/unit/test_no_dead_perquestion_paths.py @@ -27,12 +27,8 @@ def test_no_parallel_perquestion_split_helpers(): # 旧逐题分桶残留:正确率不应按 qid 直接取 assert "correctness.get(qid)" not in src, "batching 仍有逐题分桶残留" # gate 块残留探测:validate.py 是逐题 gate 核心残留点,基线缓存键须含 unit_id - assert "baseline_cache.get(" not in src or "unit_id" in src, ( - "validate baseline_cache 仍按 qid" - ) + assert "baseline_cache.get(" not in src or "unit_id" in src, "validate baseline_cache 仍按 qid" # 逐题累加残留:n_used 不应按逐题 chunk 长度累加(应按 unit) assert "n_used += len(chunk)" not in src, "validate n_used 仍逐题累加(应按 unit)" # 正向 unit 化探测:pools/batching/validate/inference 已走 unit 契约 - assert src.count("build_units") >= 1 or "unit_id" in src, ( - "pools/batching/validate 未走 unit 化" - ) + assert src.count("build_units") >= 1 or "unit_id" in src, "pools/batching/validate 未走 unit 化"