mirror of
https://github.com/Nezumi-2711/9router.git
synced 2026-09-22 13:38:31 +00:00
test(translator): add data-driven coverage, bug-exposing cases, and real provider smoke
- matrix.js generates N providers x M models from PROVIDER_MODELS - coverage-all-models + format-roundtrip for structural/semantic checks - bugs-* files expose known translation issues via it.fails - real/smoke-providers runs full handleChatCore path against live providers (RUN_REAL=1), concurrent - registerAll.js eagerly imports translators (Vitest ESM require fix) - vitest.config: array aliases for subpaths + maxConcurrency 60 Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -9,15 +9,17 @@ export default defineConfig({
|
||||
environment: "node",
|
||||
globals: true,
|
||||
include: ["**/*.test.js"],
|
||||
// Allow many it.concurrent cases (real provider smoke runs ~50 providers in parallel)
|
||||
maxConcurrency: 60,
|
||||
// Suppress noisy console output from handlers under test
|
||||
silent: false,
|
||||
},
|
||||
resolve: {
|
||||
alias: {
|
||||
// Resolve open-sse/* imports to the actual local package
|
||||
"open-sse": resolve(__dirname, "../open-sse"),
|
||||
// Resolve @/* imports to src directory
|
||||
"@": resolve(__dirname, "../src"),
|
||||
},
|
||||
// Use array form so subpath aliases (e.g. "@/lib/db/index.js") resolve correctly.
|
||||
alias: [
|
||||
{ find: /^open-sse\//, replacement: resolve(__dirname, "../open-sse") + "/" },
|
||||
{ find: "open-sse", replacement: resolve(__dirname, "../open-sse") },
|
||||
{ find: /^@\//, replacement: resolve(__dirname, "../src") + "/" },
|
||||
],
|
||||
},
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user