fix(short-drama-agent-front): 修复代码格式检查问题

This commit is contained in:
GJ committed 2026-10-21 17:04:02 +08:00
1 parent 81d6a85260
commit 48fce3975f
87 files changed
+5714 -1436

No files matched your search

@@ -18,8 +18,17 @@ function mountFields(schemas: GenerationOptionSchema[]) {
describe('生成模型参数字段', () => {
it('只有目录声明支持的模型才提供智能时长,不按模型品牌补造 -1', () => {
for (const supported of [false, true]) {
const wrapper = mountFields([{ key: 'durationSeconds', label: '生成时长', type: 'integer', required: true,
min: 4, max: 6, ...(supported ? { specialValues: [{ label: '智能时长', value: -1 }] } : {}) }])
const wrapper = mountFields([
{
key: 'durationSeconds',
label: '生成时长',
type: 'integer',
required: true,
min: 4,
max: 6,
...(supported ? { specialValues: [{ label: '智能时长', value: -1 }] } : {})
}
])
const options = wrapper.getComponent(NSelect).props('options') as { value: number }[]
expect(options.some(item => item.value === -1)).toBe(supported)
wrapper.unmount()