Files
patriothacks/vitest.config.ts

21 lines
649 B
TypeScript

import { defineConfig } from "vitest/config";
export default defineConfig({
test: {
environment: "node",
setupFiles: ["./src/lib/test-setup.ts"],
// happy-dom disables JS evaluation by default (VM-based script
// execution risk). Tests opting into the happy-dom environment need
// real <script> execution to exercise todo 54's actual direct-mount
// design (no sandbox, no isolation) rather than a stubbed-out one.
environmentOptions: {
happyDOM: {
settings: {
enableJavaScriptEvaluation: true,
suppressInsecureJavaScriptEnvironmentWarning: true,
},
},
},
},
});