mirror of
https://github.com/BeamMP/BeamMP-Website.git
synced 2026-10-12 03:24:13 +00:00
Add Vitest tests for the languages, router, footer and pages, and a lint:check script
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
import { defineConfig } from 'vite'
|
||||
import { fileURLToPath, URL } from 'node:url'
|
||||
import vue from '@vitejs/plugin-vue'
|
||||
|
||||
// Tailwind's plugin is left out on purpose: the tests check what a page says
|
||||
// and links to, not how it looks.
|
||||
export default defineConfig({
|
||||
plugins: [vue()],
|
||||
resolve: {
|
||||
alias: {
|
||||
'@': fileURLToPath(new URL('./src', import.meta.url)),
|
||||
},
|
||||
},
|
||||
test: {
|
||||
environment: 'jsdom',
|
||||
environmentOptions: {
|
||||
jsdom: { url: 'http://localhost:5173' },
|
||||
},
|
||||
globals: true,
|
||||
setupFiles: ['./tests/setup.js'],
|
||||
// The first test to mount a big view pays for compiling it too.
|
||||
testTimeout: 20000,
|
||||
hookTimeout: 20000,
|
||||
},
|
||||
})
|
||||
Reference in New Issue
Block a user