// The tests of src/lib. Vitest prefers this file to vite.config.ts, the // SvelteKit configuration of the page, so the library tests run without the // SvelteKit plugin; the page helpers in src/lib/inspector import the library // by relative paths and need no $lib alias. import { defineConfig } from 'vitest/config'; export default defineConfig({ test: { include: ['src/**/*.test.ts'], // BLS12-381 point checks and the 65 536-extension cases take a moment. testTimeout: 30_000, coverage: { provider: 'v8', include: ['src/lib/dkc/**/*.ts', 'src/lib/inspector/**/*.ts'], exclude: ['src/lib/**/*.test.ts', 'src/lib/dkc/testing/**', 'src/lib/dkc/index.ts'], reporter: ['text', 'html', 'json-summary'], thresholds: { // The codec is covered completely (plan §7). 'src/lib/dkc/cbor.ts': { 100: true }, 'src/lib/dkc/**/*.ts': { statements: 95, branches: 90, functions: 95, lines: 95 }, // The page model and helpers of the inspector (plan §8, phase 1). 'src/lib/inspector/**/*.ts': { statements: 95, branches: 90, functions: 95, lines: 95 }, }, }, }, });