feat(short-drama-agent-front): 接入首帧授权与连续性审核
This commit is contained in:
1 parent
dbf97e6f98
commit
518b630a46
35 files changed
+3070
-97
No files matched your search
@@ -83,3 +83,28 @@ describe('首帧质量正式后端契约', () => {
|
||||
expect(fetcher.mock.calls[0]![1]?.signal).toBeInstanceOf(AbortSignal)
|
||||
})
|
||||
})
|
||||
|
||||
// 同步复用回执也必须依据真实质量状态,不能只看 HTTP 200 或 passed 字段。
|
||||
describe('同步首帧质量展示门禁', () => {
|
||||
it('来源失效、待核查或存在硬错误时不显示通过,原回执保持不变', async () => {
|
||||
const { keyframeValidationPassed } = await import('@/features/production/quality')
|
||||
const result = {
|
||||
passed: true,
|
||||
summary: '历史通过',
|
||||
subjects: [],
|
||||
subjectCountConsistent: true,
|
||||
unauthorizedText: { detected: false, texts: [] },
|
||||
issues: []
|
||||
}
|
||||
expect(keyframeValidationPassed(result)).toBe(true)
|
||||
expect(keyframeValidationPassed({ ...result, qualityDecision: 'stale' })).toBe(false)
|
||||
expect(keyframeValidationPassed({ ...result, recoveryRequired: true })).toBe(false)
|
||||
expect(
|
||||
keyframeValidationPassed({
|
||||
...result,
|
||||
issues: [{ type: 'physical', severity: 'error', description: '结构冲突' }]
|
||||
})
|
||||
).toBe(false)
|
||||
expect(result.passed).toBe(true)
|
||||
})
|
||||
})
|
||||
Reference in new issue
Block a user