2022-05-19 10:21:26 +00:00
|
|
|
import { resolve as _resolve } from 'path'
|
|
|
|
import { defineConfig } from 'vitest/config'
|
|
|
|
|
|
|
|
const resolve = (p: string) => _resolve(__dirname, p)
|
|
|
|
|
|
|
|
export default defineConfig({
|
|
|
|
resolve: {
|
|
|
|
alias: {
|
|
|
|
compiler: resolve('src/compiler'),
|
|
|
|
core: resolve('src/core'),
|
2022-05-31 07:32:44 +00:00
|
|
|
server: resolve('packages/server-renderer/src'),
|
2022-06-01 14:15:27 +00:00
|
|
|
sfc: resolve('packages/compiler-sfc/src'),
|
2022-05-19 10:21:26 +00:00
|
|
|
shared: resolve('src/shared'),
|
|
|
|
web: resolve('src/platforms/web'),
|
2022-05-27 09:27:17 +00:00
|
|
|
v3: resolve('src/v3'),
|
2022-06-20 07:46:57 +00:00
|
|
|
vue: resolve('src/platforms/web/entry-runtime-with-compiler'),
|
|
|
|
types: resolve('src/types')
|
2022-05-19 10:21:26 +00:00
|
|
|
}
|
|
|
|
},
|
2022-05-24 00:55:11 +00:00
|
|
|
define: {
|
2022-06-15 02:07:42 +00:00
|
|
|
__DEV__: true,
|
|
|
|
__TEST__: true
|
2022-05-24 00:55:11 +00:00
|
|
|
},
|
2022-05-19 10:21:26 +00:00
|
|
|
test: {
|
|
|
|
globals: true,
|
|
|
|
environment: 'jsdom',
|
|
|
|
setupFiles: resolve('test/vitest.setup.ts')
|
|
|
|
}
|
|
|
|
})
|