test: lock curse yoga claim boundary

(cherry picked from commit 28f419123b0ae436e17e1d9c727bde4627ba1b91)
This commit is contained in:
732642856
2026-10-02 23:38:54 +08:00
committed by Jesse_Chen
parent 533c3a30ff
commit 9959e5149b
+15
View File
@@ -0,0 +1,15 @@
from pathlib import Path
ROOT = Path(__file__).resolve().parents[1]
def test_curse_yoga_meanings_do_not_make_deterministic_death_claims() -> None:
sources = [
ROOT / 'scripts' / 'curse_yoga_detector.py',
ROOT / 'scripts' / 'rashi_tulya_navamsa.py',
]
text = '\n'.join(path.read_text(encoding='utf-8') for path in sources)
forbidden = ('过早死亡风险', '过早死亡的风险', '可触发危险疾病或事故')
assert all(token not in text for token in forbidden)
assert '不能据此断定死亡' in text