Spaces:
Sleeping
Sleeping
File size: 939 Bytes
87b5875 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | from __future__ import annotations
import subprocess
import sys
PYTHON_FILES = [
"streamlit_app.py",
"cert_study_app/services/answer_normalizer.py",
"cert_study_app/services/demo_seed_service.py",
"cert_study_app/services/parse_quality_service.py",
"cert_study_app/services/question_review_service.py",
"cert_study_app/services/question_type_metadata_service.py",
"cert_study_app/services/quiz_service.py",
"scripts/export_hf_seed.py",
]
TEST_FILES = [
"tests/test_answer_normalizer.py",
"tests/test_question_type_metadata_service.py",
"tests/test_export_hf_seed.py",
]
def run(command: list[str]) -> None:
print("+", " ".join(command))
subprocess.run(command, check=True)
def main() -> int:
run([sys.executable, "-m", "py_compile", *PYTHON_FILES])
run([sys.executable, "-m", "pytest", *TEST_FILES])
return 0
if __name__ == "__main__":
raise SystemExit(main())
|