from pathlib import Path import sys ROOT = Path(__file__).resolve().parents[1] if str(ROOT) not in sys.path: sys.path.insert(0, str(ROOT)) from eval.real_query_runner import build_deterministic_app, evaluate_case, format_results, load_cases # noqa: E402 def main() -> int: app = build_deterministic_app() # Return a nonzero exit code so this script can be used in automation. results = [evaluate_case(app, case) for case in load_cases()] print(format_results(results)) return 0 if all(result["passed"] for result in results) else 1 if __name__ == "__main__": raise SystemExit(main())