-
Notifications
You must be signed in to change notification settings - Fork 1
/
vitest.config.ts
38 lines (36 loc) · 1.25 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
30
31
32
33
34
35
36
37
38
import path from 'path';
import { fileURLToPath, URL } from 'url';
import VueI18nPlugin from '@intlify/unplugin-vue-i18n/vite';
import vue from '@vitejs/plugin-vue';
import vueJsx from '@vitejs/plugin-vue-jsx';
import { defineConfig } from 'vitest/config';
// https://vitejs.dev/config/
export default defineConfig({
plugins: [
vue(),
vueJsx(),
VueI18nPlugin({
include: path.resolve(__dirname, './src/i18n/locales/**'),
}),
],
resolve: {
alias: {
'@pages': fileURLToPath(new URL('./src/pages', import.meta.url)),
'@stores': fileURLToPath(new URL('./src/stores', import.meta.url)),
'@app': fileURLToPath(new URL('./src/app', import.meta.url)),
'@atoms': fileURLToPath(new URL('./src/atoms', import.meta.url)),
'@molecules': fileURLToPath(new URL('./src/molecules', import.meta.url)),
'@organisms': fileURLToPath(new URL('./src/organisms', import.meta.url)),
'@templates': fileURLToPath(new URL('./src/templates', import.meta.url)),
'@plugins': fileURLToPath(new URL('./src/plugins', import.meta.url)),
},
},
test: {
globals: true,
environment: 'jsdom',
deps: {
inline: ['@vue', '@vueuse'],
},
setupFiles: ['./src/tests/server.ts', './src/tests/setup.ts'],
},
});