element-plus/vitest.config.ts
btea d0eb6c3d1a
feat: support node 18+ & update tsx and vitest (#16190)
* feat: support node 18+ & update tsx and vitest

* chore: update

* chore: remove

* fix: update dep

* test: fix autocomplete

* test: update

* test: update

* chore: update

* chore: update

* chore: update
2024-04-11 17:48:34 +08:00

33 lines
688 B
TypeScript

import { defineConfig } from 'vitest/config'
import Vue from '@vitejs/plugin-vue'
import VueJsx from '@vitejs/plugin-vue-jsx'
import VueMacros from 'unplugin-vue-macros/vite'
export default defineConfig({
plugins: [
VueMacros({
setupComponent: false,
setupSFC: false,
plugins: {
vue: Vue(),
vueJsx: VueJsx(),
},
}),
],
optimizeDeps: {
disabled: true,
},
test: {
clearMocks: true,
environment: 'jsdom',
setupFiles: ['./vitest.setup.ts'],
reporters: ['json', 'default'],
testTransformMode: {
web: ['*.{ts,tsx}'],
},
coverage: {
reporter: ['text', 'json-summary', 'json'],
},
},
})