增加即梦图片5.0和视频2.5的能力
This commit is contained in:
1 parent
542246e4ce
commit
88a4268d40
55 files changed
+1412
-200
No files matched your search
@@ -4,10 +4,12 @@ import {
|
||||
VIDEO_DURATION_DEFAULT,
|
||||
VIDEO_DURATION_MAX,
|
||||
VIDEO_DURATION_MIN,
|
||||
SEEDANCE_25_MODEL,
|
||||
clampVideoDuration,
|
||||
normalizeVideoDuration,
|
||||
normalizeVideoRatio,
|
||||
normalizeVideoResolution
|
||||
normalizeVideoResolution,
|
||||
seedanceDurationOptions
|
||||
} from "@/lib/video-settings";
|
||||
|
||||
describe("video settings", () => {
|
||||
@@ -22,6 +24,12 @@ describe("video settings", () => {
|
||||
expect(clampVideoDuration(VIDEO_DURATION_AUTO, VIDEO_DURATION_DEFAULT, { allowAuto: false })).toBe(VIDEO_DURATION_MIN);
|
||||
});
|
||||
|
||||
it("allows Seedance 2.5 durations through 30 seconds without changing 2.0", () => {
|
||||
expect(clampVideoDuration(30, VIDEO_DURATION_DEFAULT, { model: SEEDANCE_25_MODEL })).toBe(30);
|
||||
expect(clampVideoDuration(30)).toBe(VIDEO_DURATION_MAX);
|
||||
expect(seedanceDurationOptions(SEEDANCE_25_MODEL).at(-1)).toBe(30);
|
||||
});
|
||||
|
||||
it("keeps empty duration optional and falls back for invalid values", () => {
|
||||
expect(normalizeVideoDuration(undefined)).toBeUndefined();
|
||||
expect(normalizeVideoDuration("")).toBeUndefined();
|
||||
|
||||
Reference in new issue
Block a user