Files
dify/api/tests/unit_tests/models/test_evaluation.py
68609e1b09 feat(evaluation): add Evaluation workspaces and execution (#46141)
Co-authored-by: Stephen Zhou <hi@hyoban.cc>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Jyong <jyong@dify.ai>
2026-11-16 02:43:34 +00:00

20 lines
565 B
Python

from models.evaluation import EvaluationRun, EvaluationTargetType
def test_evaluation_run_progress_uses_persisted_phase_progress() -> None:
run = EvaluationRun(
tenant_id="tenant-1",
target_type=EvaluationTargetType.APPS,
target_id="app-1",
target_workflow_version_id="workflow-1",
evaluation_config_id="config-1",
config_snapshot="{}",
total_items=10,
completed_items=0,
failed_items=0,
progress_rate=0.45,
created_by="account-1",
)
assert run.progress == 0.45