-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathvitest.config.ts
29 lines (27 loc) · 1.1 KB
/
vitest.config.ts
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
import { defineConfig } from 'vitest/config';
import path from 'path';
export default defineConfig({
resolve: {
alias: {
'fast-json-stringify': require.resolve('fast-json-stringify'),
'fast-glob': require.resolve('fast-glob'),
'@cmmv/auth': path.resolve(__dirname, 'packages/auth'),
'@cmmv/cache': path.resolve(__dirname, 'packages/cache'),
'@cmmv/core': path.resolve(__dirname, 'packages/core'),
'@cmmv/http': path.resolve(__dirname, 'packages/http'),
'@cmmv/protobuf': path.resolve(__dirname, 'packages/protobuf'),
'@cmmv/repository': path.resolve(__dirname, 'packages/repository'),
'@cmmv/testing': path.resolve(__dirname, 'packages/testing'),
'@cmmv/vault': path.resolve(__dirname, 'packages/vault'),
'@cmmv/ws': path.resolve(__dirname, 'packages/ws'),
},
},
test: {
globals: true,
environment: 'node',
setupFiles: ['reflect-metadata', 'fast-json-stringify', 'fast-glob'],
env: {
NODE_ENV: 'test',
},
},
});