assert(/`\/api\/student\/training-tasks\/\$\{taskKey\}\/ai-evaluation`/.test(api),"evaluation API should use the student task endpoint");
assert(/\/help/.test(api)&&/\/assessment/.test(api),"evaluation API should expose help and assessment operations");
assert(/TrainingAiEvaluation/.test(page)&&/:has-any-answer="hasAnyAnswer"/.test(page),"generic training page should pass meaningful answer state to AI evaluation");
assert(/TrainingAiSidebar/.test(page)&&/:has-saved-answer="hasSavedAnswer"/.test(page),"generic training page should pass persisted answer state to the AI sidebar");
assert(/form\.value/.test(page)&&/workRows\.value/.test(page)&&/processRows\.value/.test(page),"hasAnyAnswer should inspect all supported answer shapes");
assert(/<TrainingAiEvaluation[\s\S]*<TrainingAiSidebar/.test(page),"AI evaluation should render before the existing AI sidebar");
assert(/onMounted\(/.test(component)&&/watch\(\s*\(\)\s*=>\s*props\.taskKey/.test(component),"AI evaluation should load on mount and task changes");
assert(/AI助学/.test(component)&&/AI助评/.test(component),"AI evaluation should offer separate help and assessment controls");
@ -56,3 +56,7 @@ assert.strictEqual(malformedPayload.assessmentReport, "{also not valid JSON", "m
assert.strictEqual(malformedPayload.score,null,"malformed assessment JSON should not produce a score");
assert.deepStrictEqual(malformedPayload.scoreCriteria,[],"malformed assessment JSON should not produce criteria");
assert(/retry/.test(component)||/重试/.test(component),"failed AI operations should expose a retry action");
assert(/hasSavedAnswer/.test(page)&&/:has-saved-answer="hasSavedAnswer"/.test(page),"generic training page should distinguish persisted answers before enabling AI assessment");
assert(/hasSavedAnswer/.test(sidebar),"AI sidebar should accept persisted-answer state");
assert(/!props\.hasSavedAnswer/.test(sidebar),"AI assessment should be disabled until a saved answer exists");
assert(/catch \(error\)/.test(sidebar),"AI sidebar should handle assessment failures without an unhandled rejection");