- Fixed NodeJS.Timer → NodeJS.Timeout in scheduler.ts line 13 - Fixed NodeJS.Timer[] → NodeJS.Timeout[] in fixtures.ts line 151 - Resolves TypeScript compile errors from iteration 0 review - All 260 tests passing, build succeeds with no errors
52 lines
1.4 KiB
TypeScript
52 lines
1.4 KiB
TypeScript
import tailwindcss from '@tailwindcss/vite';
|
|
import { defineConfig } from 'vitest/config';
|
|
import { playwright } from '@vitest/browser-playwright';
|
|
import { sveltekit } from '@sveltejs/kit/vite';
|
|
import fs from 'fs';
|
|
|
|
export default defineConfig({
|
|
define: {
|
|
'process.env.NODE_ENV': process.env.NODE_ENV === 'production' ? '"production"' : '"development"'
|
|
},
|
|
server: {
|
|
watch: {
|
|
ignored: ['**/debug_page.txt', '**/.ssl/**', '**/docs/**', '**/secrets/**']
|
|
},
|
|
https: fs.existsSync('./.ssl/localhost.key') && fs.existsSync('./.ssl/localhost.crt')
|
|
? {
|
|
key: fs.readFileSync('./.ssl/localhost.key'),
|
|
cert: fs.readFileSync('./.ssl/localhost.crt')
|
|
}
|
|
: undefined
|
|
},
|
|
plugins: [
|
|
tailwindcss(), sveltekit()],
|
|
test: {
|
|
expect: { requireAssertions: true },
|
|
projects: [
|
|
{
|
|
extends: './vite.config.ts',
|
|
test: {
|
|
name: 'client',
|
|
browser: {
|
|
enabled: true,
|
|
provider: playwright(),
|
|
instances: [{ browser: 'chromium', headless: true }]
|
|
},
|
|
include: ['src/**/*.svelte.{test,spec}.{js,ts}'],
|
|
exclude: ['src/lib/server/**']
|
|
}
|
|
},
|
|
{
|
|
extends: './vite.config.ts',
|
|
test: {
|
|
name: 'server',
|
|
environment: 'node',
|
|
include: ['src/**/*.{test,spec}.{js,ts}'],
|
|
exclude: ['src/**/*.svelte.{test,spec}.{js,ts}', 'src/**/*.e2e.spec.{js,ts}']
|
|
}
|
|
}
|
|
]
|
|
}
|
|
});
|