AI-assisted test-after framework: author Vitest tests alongside code, reproduce bugs test-first, discover untested files, run tests + coverage via MCP.
Fix bugs test-first (local TDD): write a failing test that reproduces the bug BEFORE changing any code, confirm it fails for the right reason, then fix, then confirm green. The test stays as a regression guard. Use whenever fixing a bug, correcting wrong behavior, or when the user reports something broken / "sửa lỗi" / "fix bug".
Author Vitest unit tests alongside source code (test-after) for JS/TS monorepos, especially a shared package — utils, Redux Toolkit slices, validation, formatting, calculation, AND custom React hooks. Encodes exact conventions: colocated test files, RTK reducer testing, hook testing with renderHook+jsdom, mocking native modules at the boundary, env/timer/global stubbing. Use whenever generating or modifying a util, redux slice, hook, or any pure-logic file, or when the user asks to write/add tests. Always pair new logic with a colocated test.
Admin access level
Server config contains admin-level keywords
Modifies files
Hook triggers on file write and edit operations
Own this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge. GitHub access is read-only (username + org membership).
Sign in to claimOwn this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge. GitHub access is read-only (username + org membership).
Sign in to claimBased on adoption, maintenance, documentation, and repository signals. Not a security audit or endorsement.
Uses power tools
Uses Bash, Write, or Edit tools
Uses power tools
Uses Bash, Write, or Edit tools
AI-assisted test-after framework, packaged as a Claude Code plugin. Bundles skills, a subagent, a hook, and an MCP server so that new code ships with tests and coverage gaps stay visible.
Built around the conventions of a Yarn-workspaces monorepo with a packages/shared package tested by Vitest (pure logic: utils + Redux Toolkit slices).
| Component | Type | Purpose |
|---|---|---|
write-tests | skill | Author colocated Vitest tests with the repo's exact conventions (RTK reducers, native-module mocking, env/timer/global stubbing). Auto-triggers when you touch pure-logic files. |
bug-repro | skill | Fix bugs test-first: write a failing repro test, confirm red, fix, confirm green. |
test-writer | agent | Batch-retrofit tests for untested files; runs the suite and iterates to green. |
| PostToolUse hook | hook | After editing a shared source file with no colocated test, reminds Claude to add one. Never blocks. |
test-guard MCP | mcp | list_untested_files, run_tests, coverage_report — each also writes a JSON result to <project>/.test-guard/. |
claude plugin marketplace add <github-user>/test-guard
claude plugin install test-guard@test-guard
After install, set env vars for your repo (add to ~/.zshrc or ~/.bashrc):
export TG_WORKSPACE="@myorg/shared" # yarn workspace package name (required)
export TG_SHARED_DIR="packages/shared" # path from project root to tested package (required)
export TG_SCAN_DIRS="utils,redux" # dirs to scan for untested files (default: utils,redux)
export TG_TEST_RUNNER="vitest run" # test runner cmd inside workspace (default: vitest run)
claude --plugin-dir /path/to/test-guard
claude plugin validate /path/to/test-guard
The MCP server needs @modelcontextprotocol/sdk + zod. A SessionStart hook runs
npm install in the plugin dir once if node_modules is missing. To install manually:
cd /path/to/test-guard && npm install
list_untested_files — scans packages/shared/{utils,redux} for .ts/.tsx source files lacking a colocated *.test.ts. → .test-guard/untested.jsonrun_tests (optional pattern) — runs yarn workspace @myorg/shared vitest run and returns a pass/fail summary. → .test-guard/results.jsoncoverage_report — runs Vitest v8 coverage and returns per-file/total %. → .test-guard/coverage.jsonAdd .test-guard/ to your project's .gitignore.
The shared-package path (packages/shared), workspace name (@myorg/shared),
and scanned dirs (utils, redux) are referenced in mcp/server.mjs and the skills.
Adjust those constants/paths to retarget the plugin.
npx claudepluginhub nguyenduythuc/test-guard --plugin test-guardComplete collection of battle-tested Claude Code configs from an Anthropic hackathon winner - agents, skills, hooks, and rules evolved over 10+ months of intensive daily use
Harness-native ECC operator layer - 67 agents, 271 skills, 92 legacy command shims, reusable hooks, rules, selective install profiles, and production-ready workflows for Claude Code, Codex, OpenCode, Cursor, and related agent harnesses
Comprehensive .NET development skills for modern C#, ASP.NET, MAUI, Blazor, Aspire, EF Core, Native AOT, testing, security, performance optimization, CI/CD, and cloud-native applications
Comprehensive skill pack with 66 specialized skills for full-stack developers: 12 language experts (Python, TypeScript, Go, Rust, C++, Swift, Kotlin, C#, PHP, Java, SQL, JavaScript), 10 backend frameworks, 6 frontend/mobile, plus infrastructure, DevOps, security, and testing. Features progressive disclosure architecture for 50% faster loading.
Binary reverse engineering, malware analysis, firmware security, and software protection research for authorized security research, CTF competitions, and defensive security
v9.44.1 — Patch release for Gemini environment/version detection and qwen auth gating. Run /octo:setup.