Failing Test First
Takes a bug report and writes the smallest test that fails for the right reason, before anything is fixed.
Free — no card needed
Create a free account
to open Failing Test First — and the other 364 prompts across 21 categories.
Already have an account?
Running it, start to finish
- Paste the bug report, the code and a sample of your existing tests.
- Run the generated test and compare against the section 4 prediction.
- Only apply the fix once the failure matches.
What you get back
The output this produces, every time.
- Writes the test before the fix, and predicts the exact failure so a wrong diagnosis is caught immediately.
- Reduces the reported case to the smallest input that still reproduces it.
- Suggests neighbouring cases likely broken by the same root cause.
Getting better results
Where this usually goes wrong, and how to avoid it.
- Run the test before reading section 5. That is the whole point of the ordering. If the failure does not match the prediction, stop and re-diagnose rather than applying the fix.
- Paste real test files. as the framework context, not just the framework name. Conventions matter more than syntax for whether the test fits the suite.
- Take the scaffolding complaint seriously. If it says the test needs heavy setup, that is usually a real finding about coupling, not a limitation of the test.
More Coding prompts
All Coding →- Coding
Refactor With a Safety Net
Plans a refactor as a sequence of individually safe, individually shippable steps, with the characterisation tests that make each one verifiable.
ClaudeChatGPT000Open → - Coding
Review for the Bug, Not the Style
A code review that hunts correctness failures and states the exact input that breaks each one, instead of listing naming preferences.
ClaudeChatGPTGemini000Open → - Coding
Database Migration Plan
Plans a schema change that ships without downtime, in steps that are each independently safe and reversible.
ClaudeChatGPT000Open →
Written for The AI University. Every prompt in this library is original work — authored, tested and revised here, not collected from elsewhere. 365 of them, free with an account.
