import pytest import json from pathlib import Path SCHEMA_PATH = Path("../schemas/model_registry.schema.json") def test_schema_valid(): """Test that schema is valid JSON""" schema = json.loads(SCHEMA_PATH.read_text()) assert schema["$schema"] == "http://json-schema.org/draft-07/schema#" assert "properties" in schema def test_eval_reports_exist(): """Test that all eval reports exist""" eval_path = Path("../evaluation_reports") reports = list(eval_path.glob("*.md")) assert len(reports) >= 3, "Expected at least 3 eval reports" def test_eval_report_content(): """Test eval report structure""" reports = Path("../evaluation_reports").glob("*.md") for report in reports: content = report.read_text() assert "## Model" in content assert "## Evaluation Results" in content assert "## Recommendation" in content if __name__ == "__main__": pytest.main([__file__, "-v"])