-
-
Notifications
You must be signed in to change notification settings - Fork 351
Expand file tree
/
Copy pathvitest.shared.ts
More file actions
30 lines (29 loc) · 766 Bytes
/
Copy pathvitest.shared.ts
File metadata and controls
30 lines (29 loc) · 766 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
import { defineConfig } from 'vitest/config'
import react from '@vitejs/plugin-react'
export default defineConfig({
plugins: [react()],
test: {
environment: 'jsdom',
globals: true,
setupFiles: [new URL('./vitest.setup.ts', import.meta.url).pathname],
include: ['__tests__/**/*.test.{ts,tsx}'],
css: false,
coverage: {
provider: 'v8',
reporter: ['text', 'json-summary', 'html'],
reportsDirectory: './coverage',
include: ['**/*.{ts,tsx}'],
exclude: [
'**/__tests__/**',
'**/dist/**',
'**/node_modules/**',
'**/*.d.ts',
'**/index.tsx',
'**/types.tsx',
'**/styles.tsx',
'**/build.config.ts',
'**/vitest.config.ts',
],
},
},
})