AI Test Generation Prompt Pack
AI can write tests in seconds. Without structure, most of them can’t fail.
Ask a model to “write tests for this file” and you typically get: expected values computed with the same formula as the code, mocks standing in for the thing under test, a dozen happy-path variations, and — in agent mode — a quiet edit to production code so everything turns green.
AI Test Generation Prompt Pack gives you ready-to-paste prompts with roles, placeholders, a plan-before-code process, output contracts and hard rules, so Cursor, Claude Code, ChatGPT or Copilot Chat return tests you can defend in review.
This is NOT an AGENTS.md / agent-workflow pack and NOT a PR-review pack. It is only about writing and improving automated tests.
What you get:
- PDF field guide (27 pages)
- templates/ — 8 prompts + 2 checklists + Cursor .mdc rule + README
- cover.png
The 8 prompts:
1. Unit tests from existing code
2. Tests from spec / behaviour (TDD-friendly)
3. Integration & API tests
4. E2E user journey
5. Characterization tests for legacy code
6. Flaky test diagnosis
7. Coverage gap → prioritized plan
8. Mock / stub boundary strategy
Also: test quality checklist, when NOT to test guide, Cursor rule for plan-first test generation.
Works with Cursor, Claude Code, ChatGPT and Copilot Chat. No fake stats.