Lecture 11 · 2 min read

End-to-End Testing Changes Results

An agent can turn every unit test green and still ship something broken, because the bug is hiding in the seams between the pieces. Only a real end-to-end run touches those seams.

💡Test-drive the car, not just the engine

An engine that passes on the bench can still stall in traffic, because the failures live in the wiring between the parts. Unit tests bench-test the parts; an end-to-end run is the test drive. Agentum adds a second gate that exercises the product the way a user would.


The bugs live in the seams

Unit tests confirm each component in isolation; self-review confirms the agent's own mental model. Neither touches the integration boundaries, the wiring, the config, the real I/O where most production failures actually occur. A green unit suite next to a broken product is a very common, very misleading state.

flowchart LR
  Unit["verify.sh, unit gate"] -->|green| RT["ready_to_test"]
  RT --> QA["Browser QA, Chrome via MCP"]
  QA -->|verdict pass| Done["done"]
  QA -->|inconclusive| Fail["gate fails"]
  linkStyle 0 stroke:#2ea043,stroke-width:2.5px,color:#2ea043
  linkStyle 2 stroke:#2ea043,stroke-width:2.5px,color:#2ea043
  linkStyle 3 stroke:#e0493f,stroke-width:2.5px,color:#e0493f
Two phases: the unit gate, then a real browser pass.

What an end-to-end gate changes

When the verification gate runs the whole pipeline the way a user would, two things change. First, you catch the integration failures that unit tests structurally cannot. Second, and more subtly, the agent starts building for the end-to-end reality, because that is what gets graded. The shape of the gate shapes the work; a full-pipeline gate produces software that actually runs.

The two-phase gate

Agentum builds the end-to-end principle into a two-phase gate. First verify.sh runs as the unit gate. When it passes, the feature moves to ready_to_test and a second, browser-level gate runs: depending on qa_mode, either a qa.sh script or a real browser-verification-loop agent that drives Chrome through the Playwright/CDP MCP and writes a verdict to .agentum-harness/qa/<id>.json. An inconclusive verdict fails the gate. Only when both phases are green does the feature reach done, the product is checked the way a user would actually exercise it.

Key takeaways

  • Unit tests and self-review miss integration failures, the seams between units.
  • An end-to-end gate catches what unit tests structurally cannot.
  • The shape of the gate shapes the work: grade the whole pipeline and the agent builds for it.
  • Agentum runs against a real environment, so verification can be a genuine end-to-end run.

Exercises

  1. Find the seam. Name one bug that all your unit tests would miss. What end-to-end check would catch it?
  2. Write one e2e. Script the single most important user path from end to end.

Further reading

This lecture reframes the matching chapter of the open Walking Labs course for Agentum. Read the original ↗