We raised $3M for agent-native runners

Keep unit tests independent of slow services

Use controlled substitutes for external dependencies when the test is intended to verify local behavior, keeping integration coverage separately.

How companies used this technique

Read what each company changed and follow the original sources.

Mock the slow dependency

OpenAI added a missing mock to a 63-test resolver suite and kept all 63 tests. In the public evals repository, the workflow validates new evaluations against dummy chat and completion models, so the check runs without a live model call.

63-test resolver suite: 592.6s to 29.8s after adding the missing mock Source

Use it when
A slow test calls a real dependency outside the code it exists to verify.
Before applying it
Keep one job that exercises the real dependency, nightly or after merge. A deterministic mock proves the code under test, and the live job proves the service.

Keep unit tests independent of database servers

Cadence removed Cassandra, MySQL, PostgreSQL and MongoDB services from its unit-test container. Component tests that only needed persistence switched to SQLite, and database-specific persistence and CLI tests moved into the integration tree, whose Makefile gained an explicit discovery pass. OPT87's boundary-isolation recipe is adapted with a local SQLite store.

The PR reports unit and integration test runs and a comparison of coverage reports. Source

Use it when
Unit or component checks wait for database servers whose engine-specific behavior they never exercise.
Before applying it
Keep real-engine integration tests and compare their discovered test sets and combined coverage, since unit-only coverage shifts when tests move. The server-startup test also drops a Cassandra schema-version assertion; keep an equivalent engine-specific check in the integration lane.

Company Playbooks