test: 为分镜页面新增的时长预算请求补充明确 Mock
This commit is contained in:
1 parent
58337382b9
commit
c456bf6865
1 file changed
+13
@@ -100,6 +100,19 @@ function stubFetch(fetcher: Mock<typeof fetch>) {
|
|||||||
const path = String(url)
|
const path = String(url)
|
||||||
if (path.endsWith('/generation-models')) return jsonResponse(imageCatalog)
|
if (path.endsWith('/generation-models')) return jsonResponse(imageCatalog)
|
||||||
if (path.endsWith('/creative-profile')) return jsonResponse(generationProfile(fixture.id))
|
if (path.endsWith('/creative-profile')) return jsonResponse(generationProfile(fixture.id))
|
||||||
|
if (path.endsWith('/duration-budget'))
|
||||||
|
return jsonResponse({
|
||||||
|
projectId: fixture.id,
|
||||||
|
mode: 'auto',
|
||||||
|
episodeCount: 1,
|
||||||
|
targetDurationSeconds: null,
|
||||||
|
episodeMinSeconds: null,
|
||||||
|
episodeMaxSeconds: null,
|
||||||
|
episodes: [{ episodeNo: 1, targetDurationSeconds: null, plannedSeconds: null, shotSeconds: null, shotCount: 0, audit: null }],
|
||||||
|
targetWarningCount: 0,
|
||||||
|
willCallModel: false,
|
||||||
|
willModifyAssets: false
|
||||||
|
})
|
||||||
if (path.endsWith('/storyboard/duration-audit'))
|
if (path.endsWith('/storyboard/duration-audit'))
|
||||||
return jsonResponse({
|
return jsonResponse({
|
||||||
projectId: fixture.id,
|
projectId: fixture.id,
|
||||||
|
|||||||
Reference in new issue
Block a user