R220 · AI-built software and its verification › Test oracles for agent-written code

Accept agent code on evidence, not line-by-line review

Read the original

Authors Paul Iusztin, matt-pocock, The Pragmatic Engineer

test-oraclescode-reviewcoding-agentstddpractitioner-advice

Sources: Paul Iusztin (author and AI engineer, Manning), LinkedIn post, 2026-11-22. Matt Pocock (TypeScript educator, creator of the grill-me agent skill), speaking on The Pragmatic Engineer podcast with Gergely Orosz, episode "AI Skills with Matt Pocock" (2026-09-17), clipped on LinkedIn on 2026-11-22.

The claim

Two practitioners land in the same place from different directions.

Put together, the reviewer's job moves from reading diffs to auditing evidence. The reviewer checks that the checks are real.

The acceptance pipeline this implies

  1. Spec first. Acceptance criteria are written before the agent starts, so "does what I asked" can be checked.

  2. Fail-without-change proof. For each behavioural change, the agent shows the new or changed test failing on the base revision and passing on the branch.

  3. Test-quality gate. Tautological or implementation-mirroring tests are rejected. Mutation testing or a "revert the fix, does the test go red?" check catches them mechanically.

  4. Static, type and security analysis run as required checks, not suggestions.

  5. Realistic environment run. Integration or staging tests on production-shaped data.

  6. Risk-based human reading. Full line review is triggered by path (auth, payments, migrations, concurrency), by novelty, or by a failed check, not by default.

Tradeoffs

Failure modes

  1. Tautological tests pass forever and prove nothing.

  2. Agent edits the oracle: it weakens or deletes a failing test to get green.

  3. Check coverage gaps: no check for performance, accessibility or data privacy, so regressions there are invisible.

  4. "Critical code" not defined in advance, so everything gets waved through.

  5. Flaky tests misread as proof in either direction.

Review checklist

Cited in field guides

Connections

See R220 on the knowledge map

Part of the Research notes on nowucca.com. Figures and claims are the source's own unless the summary says otherwise.