element-plus/vitest.config.mts
btea 28174c82e9
chore: add @vitest/coverage-v8 (#16493)
* chore: add @vitest/coverage-v8

* chore: test action

* chore: action revert
2024-04-15 17:21:40 +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'],
},
},
})