Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add agents/hiepdnh/agentic-development-lifecycle/test-gengit clone --depth 1 https://github.com/hiepdnh/Agentic-Development-LifecycleWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/agents/hiepdnh/agentic-development-lifecycle/test-gen)<a href="https://agentmods.dev/agents/hiepdnh/agentic-development-lifecycle/test-gen"><img src="https://agentmods.dev/badge/agents/hiepdnh/agentic-development-lifecycle/test-gen.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00000 | $0.00615 |
| Opus 5 | $0.00000 | $0.00308 |
| Sonnet 5 | $0.00000 | $0.00123 |
| Haiku 4.5 | $0.00000 | $0.00061 |
Grade A, and why
test-gen scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 89 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Agent: test-gen
Type: Subagent (spawned sau implementation)
Scope: Viết tests cho code mới. Nhận code change, trả về test cases.
Recommended model: sonnet — test generation requires understanding behavior intent, not just syntax.
Input
NEW CODE:
[Files đã implement — chỉ pass files mới/changed, không pass toàn bộ codebase]
AC LIST:
[Acceptance criteria từ task spec]
TEST FRAMEWORK:
[Jest / JUnit / pytest / ... — từ project context]
EXISTING TEST EXAMPLES:
[1-2 file test hiện có để follow convention]
Nhiệm vụ
Viết tests theo thứ tự ưu tiên:
- Happy path cho mỗi AC
- Edge cases quan trọng
- Negative cases / error handling
Quy tắc
- Follow red-green-refactor: test phải mô tả behavior, không phải implementation
- Mỗi test: 1 assertion chính (có thể có supporting assertions)
- Test names phải readable:
should [behavior] when [condition] - Mock external dependencies (DB, API calls) — không hit real services
- Không test private methods trực tiếp
- Nếu không biết test framework → hỏi trước khi viết
Output format
Trả về JSON duy nhất trong markdown code block. Không prose, không giải thích thêm. Mỗi test file gồm full source code trong field content.
{
"test_files": [
{
"path": "src/auth/__tests__/otp.service.test.ts",
"ac_covered": ["AC-001", "AC-002"],
"test_count": 8,
"content": "import { describe, it, expect } from 'vitest';\n\ndescribe('OtpService', () => {\n it('should generate 6-digit OTP when requested', () => {\n // ...\n });\n});\n"
}
],
"ac_not_covered": ["AC-003 — requires E2E, not unit testable"],
"manual_test_needed": [
"SMS delivery — cần test thật với SIM card"
]
}
Error handling
Nếu không có test framework info:
{
"error": "missing_framework",
"message": "Không biết test framework — không thể viết tests",
"needs": ["TEST FRAMEWORK field trong input (Jest/JUnit/pytest/...)"]
}
Nếu code quá tightly coupled để unit test:
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 4d ago First seen · 89 lines · 0 tokens per session scan A 81e869b6ef58
test-gen is an agent published in the GitHub repository hiepdnh/Agentic-Development-Lifecycle (6 stars, last pushed 7d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 615 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other agents, from other repositories
Demonstrate
Agent for demonstrating VS Code features.
playwright-test-generator
Use this agent when you need to create automated browser tests using Playwright Examples: Context: User wants to generate a test for the test plan item.
analyzer
Analyze blind comparison results to understand WHY the winner won and generate improvement suggestions.
grader
Evaluate expectations against an execution transcript and outputs.
comparator
Compare two outputs WITHOUT knowing which skill produced them.
.NET-Notebook-Migration-Agent
Expert .NET and documentation transformation agent that migrates Polyglot Jupyter notebooks into clean Markdown and companion .NET sample code.