
Zod 4 compiles fine and still changes what your API accepts. A baseline recorded on 3.x, a test that replays it on 4.x and a two-file rule for the agent turn the upgrade into a short list of decisions. About 30 minutes on one project.

Agent-written C# reaches for DateTime.UtcNow by default. A fake clock, three boundary tests and one analyzer rule fix it in about 20 minutes.

A build setting, one test and a ten-line script turn a new enum member into a failing build everywhere it matters. About 15 minutes to set up.

Vitest 5 changes what some passing tests mean, and 'make the suite pass' invites the cheapest fix. A baseline, a test-only rule and a short gate script keep the upgrade honest. About 20 minutes on one project.

An agent-written signup form with a div for a button and no label sailed through axe in Vitest. Adding two role-based assertions caught what axe didn't. Setup takes about fifteen minutes.

Agents change code faster than anyone rereads the docs. A 40-line Vitest file turns every TypeScript example in a README into a test, so stale docs fail the build. Fifteen minutes to set up.

A short Stop hook that runs the test suite when Codex tries to finish, feeds the failure back as the next prompt, and gives up after three tries. Ten minutes to wire in.

A PostToolUse hook with asyncRewake runs your suite after each edit without blocking the agent, stays silent on a pass and wakes Claude Code with a trimmed failure report on a fail. Fifteen minutes to set up.

Tell an agent a test is flaky and it will add a retry. This setup makes it measure the failure rate, replay a failing seed and prove the fix, and it blocks the commit if the 'fix' is a retry, a sleep or a skip. About 15 minutes to try.

A recorder, a generated test file and a mutation run give you a safety net you can measure, not just feel good about. About 20 minutes to set up.

A script that fails the pull request when the diff skips a test, lowers a coverage threshold or adds || true. Ten minutes to wire in.

An agent's first test suite for old code usually checks what you'd expect, not what the code does. Mutation testing shows the difference in under a minute.

Anthropic's engineering team spent nearly $20,000 on it. The lessons about tests, locks and duplicate code transfer to much smaller jobs.

A Stop hook turns 'please run the tests' from a request into a rule. Here's a working setup and the trap to avoid.