k8s-set-context/vitest.config.ts
Suneha Bose fc3887264c
Migrate to ESM, esbuild, vitest, and update actions/* to latest
- Update @actions/core to 3.x, @actions/exec to 3.x, @actions/io to 3.x
- Replace @vercel/ncc + babel with esbuild (build.mjs) targeting Node 20 ESM
- Replace jest/babel-jest/ts-jest with vitest and @vitest/coverage-v8
- Update tsconfig to NodeNext module resolution with strict mode
- Add explicit .js extensions to all relative imports (NodeNext requirement)
- Fix implicit any index signatures in parseCluster and parseMethod
- Migrate all test files from jest to vi.mock/vi.mocked APIs
- Fix ESM module spying limitations using vi.mock() at module level
- Fix env var test pollution in default.test.ts with afterEach cleanup
2026-03-25 10:54:37 -07:00

21 lines
415 B
TypeScript

import {defineConfig} from 'vitest/config'
export default defineConfig({
test: {
globals: true,
environment: 'node',
include: ['src/**/*.test.ts'],
restoreMocks: true,
clearMocks: true,
coverage: {
provider: 'v8',
thresholds: {
branches: 0,
functions: 40,
lines: 22,
statements: 22
}
}
}
})