vite/vitest.config.e2e.ts
patak f684d4cd5c
feat: environment api (#16129)
Co-authored-by: Vladimir Sheremet <sleuths.slews0s@icloud.com>
Co-authored-by: Hiroshi Ogawa <hi.ogawa.zz@gmail.com>
Co-authored-by: 翠 / green <green@sapphi.red>
Co-authored-by: Jun Shindo <46585162+jay-es@users.noreply.github.com>
Co-authored-by: Greg T. Wallace <greg@gregtwallace.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Caven <cavenasdev@gmail.com>
Co-authored-by: sapphi-red <49056869+sapphi-red@users.noreply.github.com>
Co-authored-by: Matyáš Racek <panstromek@seznam.cz>
Co-authored-by: bluwy <bjornlu.dev@gmail.com>
2024-04-19 14:42:21 +02:00

37 lines
936 B
TypeScript

import { resolve } from 'node:path'
import { defineConfig } from 'vitest/config'
const timeout = process.env.PWDEBUG ? Infinity : process.env.CI ? 50000 : 30000
export default defineConfig({
resolve: {
alias: {
'~utils': resolve(__dirname, './playground/test-utils'),
},
},
test: {
include: ['./playground/**/*.spec.[tj]s'],
setupFiles: ['./playground/vitestSetup.ts'],
globalSetup: ['./playground/vitestGlobalSetup.ts'],
testTimeout: timeout,
hookTimeout: timeout,
reporters: 'dot',
deps: {
// Prevent Vitest from running the workspace packages in Vite's SSR runtime
moduleDirectories: ['node_modules', 'packages'],
},
onConsoleLog(log) {
if (
log.match(
/experimental|jit engine|emitted file|tailwind|The CJS build of Vite/i,
)
)
return false
},
},
esbuild: {
target: 'node18',
},
publicDir: false,
})