refactor(desktop): structure suggestion pipeline and restore test gates
This commit is contained in:
parent
fe0989c456
commit
1d4f8d8401
17 changed files with 813 additions and 569 deletions
|
|
@ -1,11 +1,20 @@
|
|||
import { defineConfig } from 'vitest/config'
|
||||
import { resolve } from 'path'
|
||||
|
||||
export default defineConfig({
|
||||
const TEST_INCLUDE: Record<string, string[]> = {
|
||||
all: ['tests/**/*.{test,spec}.ts'],
|
||||
integration: ['tests/integration/**/*.{test,spec}.ts'],
|
||||
eval: ['tests/eval/**/*.{test,spec}.ts'],
|
||||
unit: ['tests/unit/**/*.{test,spec}.ts'],
|
||||
service: ['tests/{main,red}/**/*.{test,spec}.ts'],
|
||||
offline: ['tests/{unit,main,red}/**/*.{test,spec}.ts']
|
||||
}
|
||||
|
||||
export default defineConfig(({ mode }) => ({
|
||||
test: {
|
||||
globals: true,
|
||||
environment: 'node',
|
||||
include: ['tests/**/*.{test,spec}.ts'],
|
||||
include: TEST_INCLUDE[mode] ?? TEST_INCLUDE.offline,
|
||||
exclude: ['tests/e2e/**'],
|
||||
setupFiles: ['tests/setup.ts'],
|
||||
testTimeout: 10000,
|
||||
|
|
@ -22,4 +31,4 @@ export default defineConfig({
|
|||
'@d3ro/i18n': resolve(__dirname, '../../packages/i18n/src/index.tsx')
|
||||
}
|
||||
}
|
||||
})
|
||||
}))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue