fix(short-drama-agent-front): 修复测试警告与请求模拟

This commit is contained in:
GJ committed 2026-10-15 18:10:19 +08:00
1 parent 46f54548c7
commit a9370cdf50
8 files changed
+67 -18

No files matched your search

+2
View File
@@ -8,6 +8,8 @@ export default defineConfig({
resolve: { alias: { '@': fileURLToPath(new URL('./src', import.meta.url)) } },
test: {
environment: 'happy-dom',
/** 全量测试统一检测警告,并阻止遗漏模拟的请求连接真实服务。 */
setupFiles: ['./tests/setup.ts'],
restoreMocks: true,
/** 限制同时挂载的页面测试数量,避免 Naive UI 渲染争抢资源造成超时。 */
maxWorkers: 2,