From dee6bf48967aa8fbd5856cebf6c5c5ad927c5a11 Mon Sep 17 00:00:00 2001 From: iomgaa Date: Wed, 15 Jul 2026 07:09:54 -0400 Subject: [PATCH] test: assert specific missing question_id in T6 invariant error match --- tests/unit/test_inference_pair_aggregate.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/unit/test_inference_pair_aggregate.py b/tests/unit/test_inference_pair_aggregate.py index fb2faf1..7d07aa8 100644 --- a/tests/unit/test_inference_pair_aggregate.py +++ b/tests/unit/test_inference_pair_aggregate.py @@ -274,7 +274,7 @@ class TestUnitLevelAggregation: _make_question("s2", answer="A"), ] records = [_make_record("s1", prediction="B", answer="B")] # 缺 s2 的 record - with pytest.raises(ValueError, match=r"缺 prediction.*聚合不变量被破坏"): + with pytest.raises(ValueError, match=r"s2.*缺 prediction.*聚合不变量被破坏"): _aggregate_results(records, questions, "run-broken-invariant") def test_empty_records_returns_zero(self) -> None: