reuse vite.config in vitest.config

This commit is contained in:
Ulf Gebhardt 2023-11-16 12:55:29 +01:00
parent e6f34c0a81
commit 6fbce556a7
Signed by: ulfgebhardt
GPG Key ID: DA6B843E748679C9

View File

@ -1,18 +1,21 @@
import vue from '@vitejs/plugin-vue' // Import the plugin here
import { defineConfig } from 'vitest/config'
import { defineConfig, mergeConfig } from 'vitest/config'
export default defineConfig({
test: {
globals: true,
environment: 'jsdom',
setupFiles: ['tests/unit.setup.ts'],
/*
server: {
deps: {
inline: ['vuetify'],
import viteConfig from './vite.config'
export default mergeConfig(
viteConfig,
defineConfig({
test: {
globals: true,
environment: 'jsdom',
setupFiles: ['tests/unit.setup.ts'],
/*
server: {
deps: {
inline: ['vuetify'],
},
},
*/
},
*/
},
plugins: [vue()], // Include it in your array of plugins here
})
}),
)