Files
Codewalkers/vitest.config.ts
Lukas May c0096503b2 fix: Re-record cassettes and exclude workdir from test discovery
Re-recorded all 4 cassette files to reflect current prompt templates.
Added `workdir/**` to vitest exclude list to prevent test discovery
in agent worktree directories.
2026-03-06 17:00:46 +01:00

33 lines
888 B
TypeScript

import { defineConfig } from 'vitest/config';
import react from '@vitejs/plugin-react';
import path from 'node:path';
export default defineConfig({
plugins: [react()],
resolve: {
alias: {
'@': path.resolve(__dirname, './apps/web/src'),
},
},
test: {
// Enable test globals (describe, it, expect without imports)
globals: true,
env: {
CW_LOG_LEVEL: 'silent',
},
// Test file pattern
include: ['**/*.test.ts', '**/*.test.tsx'],
exclude: ['**/node_modules/**', '**/dist/**', 'packages/**', 'workdir/**'],
environmentMatchGlobs: [
['apps/web/**', 'happy-dom'],
],
// TypeScript support uses tsconfig.json automatically
// Coverage reporter (optional, for future use)
coverage: {
provider: 'v8',
reporter: ['text', 'json', 'html'],
reportsDirectory: './apps/server/coverage',
},
},
});