26 lines
1.1 KiB
Python
26 lines
1.1 KiB
Python
from app.agents.evaluation_agent import evaluate_project
|
|
from app.agents.validation_agent import validate_project
|
|
|
|
|
|
def test_evaluation_agent_returns_checks():
|
|
result = evaluate_project()
|
|
assert result["agent"] == "evaluation_suggestion_agent"
|
|
assert result["passed"] is True
|
|
assert result["checks"]
|
|
assert result["summary"]["passed_checks"] == result["summary"]["total_checks"]
|
|
checks = {item["name"]: item["passed"] for item in result["checks"]}
|
|
assert checks["real_workspace_acceptance"] is True
|
|
assert checks["real_train_acceptance"] is True
|
|
assert checks["single_epoch_curve_support"] is True
|
|
assert checks["separated_pages_ui"] is True
|
|
assert checks["trained_model_inference_ui"] is True
|
|
assert checks["dataset_preparation_doc"] is True
|
|
|
|
|
|
def test_validation_agent_lightweight(monkeypatch):
|
|
monkeypatch.setenv("SEG_VALIDATE_LIVE", "0")
|
|
result = validate_project(run_build=False, run_deep=False)
|
|
assert result["agent"] == "validation_agent"
|
|
assert result["passed"] is True
|
|
assert any(item["name"] == "catalog_has_yolo_heatmap" for item in result["checks"])
|