Vitest reporter for TDD Guard
npm install tdd-guard-vitestVitest reporter that captures test results for TDD Guard validation.
- Node.js 18+
- Vitest 3.2.0+
- TDD Guard installed globally
``bash`
npm install --save-dev tdd-guard-vitest
Add the reporter to your vitest.config.ts:
`typescript
import { defineConfig } from 'vitest/config'
import { VitestReporter } from 'tdd-guard-vitest'
export default defineConfig({
test: {
reporters: ['default', new VitestReporter()],
},
})
`
For workspaces or monorepos, pass the project root path to the reporter:
`typescript
// vitest.config.ts in project root
import { defineConfig } from 'vitest/config'
import { VitestReporter } from 'tdd-guard-vitest'
import path from 'path'
export default defineConfig({
test: {
reporters: ['default', new VitestReporter(path.resolve(__dirname))],
},
})
`
If your vitest config is in a workspace subdirectory, pass the absolute path to your project root:
`typescript`
new VitestReporter('/Users/username/projects/my-app')
- Test results are saved to .claude/tdd-guard/data/test.json`
- See TDD Guard documentation for complete setup
MIT