feat: add testing framework and initial test cases

- Updated package.json to include Vitest and testing dependencies.
- Created test cases for SuitePicker component to validate selection logic.
- Added tests for ReportsPage to ensure correct report grouping and ordering.
- Implemented read-only enforcement tests for SuitePage to prevent actions on built-in suites.
- Introduced a setup file for Vitest to include jest-dom matchers and cleanup after tests.
- Modified ReportsPage to group reports by model and display them accordingly.
- Enhanced API types to include suite_scope and question_count for better report handling.
This commit is contained in:
Netherwarlord
2026-07-28 20:06:26 -04:00
parent 8f246fabbc
commit 7a81468925
26 changed files with 2487 additions and 168 deletions
+4 -1
View File
@@ -202,7 +202,10 @@ def _apply_plugins_to_report(report_path, records, grades, provider, model, star
yields the same report.
"""
plugins = get_plugin_manager()
label = report_path.stem.replace("automated_report_", "")
# The model is what the caller asked for. Deriving it from the filename was
# already fragile and is now wrong, since the name carries a timestamp,
# suite scope and question count as well.
label = model or report_path.stem.split("__", 1)[0]
record = RunRecord(
id=f"cli-{int(started_at)}",