from pathlib import Path
import json
R=Path(__file__).resolve().parent
cases=json.loads((R/'fixtures/cases.json').read_text(encoding='utf-8'))['cases']
assert len(cases)==8
for c in cases:
    assert c['id'] and c['claim']
    assert c['source_authority'] in {'HIGH','MEDIUM','LOW','UNKNOWN'}
    assert c['entailment'] in {'ENTAILS','CONTRADICTS','IRRELEVANT','AMBIGUOUS','NONE'}
    assert c['freshness'] in {'FRESH','STALE','UNKNOWN'}
    assert isinstance(c['model_confidence'],(int,float))
    assert 'post_entailment' in c and 'post_freshness' in c
print('PASS learner fixtures: 8 hallucinated-claim evidence cases')
