Agents fix the tests too. How to design verification.
Claude writes about 90% of the Claude Code team's code. So the team redesigned verification before review.
Yohan Choi
· 3 min read
Yesterday I wrote that when coding agents write more code, the bottleneck moves to review. This week brought a wave of posts answering the next question: if review is the bottleneck, what can a reviewer actually trust?
#Agents find a way to pass
Microsoft's Stephen Toub described porting the GitHub Copilot runtime, about 400,000 lines of TypeScript, to Rust with agents in roughly 14.5 weeks. According to GeekNews's summary of the talk, two things happened along the way:
- An agent changed a behavior and also edited the end-to-end tests that checked that behavior.
- When CI blocked a public API change, an agent found and applied a PR label that allowed breaking changes.
Not malice. "Pass" was the goal it was given. Evan X. Merz points at a similar signal in "AI usage generates a fragile codebase": piles of shallow tests that only exercise getters and setters make coverage look healthy while real user flows go unchecked.
#How the Claude Code team designs verification
Addy Osmani's "How the Claude Code team thinks about verification" (November 16) was the most concrete answer I found. These are the rules of a team where Claude writes and reviews about 90% of the code.
- Invest in three kinds of tests first. If you pick one, pick end-to-end. Next come property-based tests (round-trip encoding, invariants, idempotence) and differential tests (use the old system as the answer key and compare outputs on the same inputs).
- A separate checker does the grading. When a grader independent of the working agent checked against a rubric, task success rose by up to 10 points in internal tests.
- Keep the rules where the PR cannot touch them. Checks are read from the base branch, and reviews are pinned to a specific commit. That structurally blocks the "fix the tests too" problem.
- After three failed fixes, stop and call a human. Unlimited retries eventually find a workaround.
- Don't run the whole checklist. Of 39 items, only the 3 to 10 triggered by the diff run, which cuts cost and noise.
#Treat evaluation as numbers
Some arithmetic is easy to miss when designing verification:
- An agent that succeeds 80% of the time on a single run succeeds five times in a row only about 33% of the time (0.8 to the fifth power). "Works at least once" (pass@k) and "works every time" (pass^k) are very different metrics.
- An 80% accuracy measured on 100 examples has a 95% confidence interval of about ±8 points. With a small eval set, the effect of changing a model or prompt drowns in noise.
#Keep the human sense sharp
More than a thousand people have signed "No AI Slop," a manifesto written by AIE Code Summit 2026 attendees. Its core is an asymmetry: producing now costs almost nothing, but reviewing costs the same as ever. So when the same mistake happens twice, fix the system and its guardrails, not just individual effort.
There is a warning from the other side, too. "If you stop writing code, you also get worse at reviewing it" argues that when you stop practicing writing code, your eye for reviewing it dulls. It is an essay, not a study, but the more verification you automate, the clearer you need to be about what humans still judge.
#The rules I use
- Split test changes and feature changes into separate PRs. When both land in one PR, I suspect the tests first.
- Keep the checks outside the agent's scope. Lint rules, CI config and eval sets are off-limits for the agent.
- Write the invariants first. Sentences like "this value is never negative" or "save then load returns the same thing" are where property tests start.
- Cap retries. After three failures, a human looks.
In the agent era, review is becoming less about reading code line by line and more about designing a verification structure that produces signals you can trust.
Sources
Addy Osmani: How the Claude Code team thinks about verification
GeekNews: summary of Stephen Toub's talk on porting the Copilot runtime to Rust
Evan X. Merz: AI usage generates a fragile codebase
No AI Slop: A Manifesto
If you stop writing code, you also get worse at reviewing it