Skip to content
Business Efficiency Talking point

Bun's creator trusts tests that the agent could not have touched

Jarred Sumner says tests that predate a project are what let his team trust agent-written code.

W
WebPulse Newsroom
AI-assisted · 2 min read
Share on X LinkedIn
Bun's creator trusts tests that the agent could not have touched

Graphic: WebPulse, drawn from the sourced facts in this story.

In brief
  • Jarred Sumner said his team largely trusts tests written before a project began, because the agent could not have altered them.
  • A team that rewrites its tests along with its code loses a check it can largely trust, Sumner argues.

Tests that existed before a project began are what let a team largely trust agent-written code. That was the argument of Jarred Sumner, creator of the Bun JavaScript runtime, on the AI Engineer podcast. He described a pull request of several million lines, written largely by agents. In his telling, how you test decides what approach you can take.

What was said

Sumner said the way you test your code limits what you can attempt. He put it plainly: "you're really constrained by how you test that the code works."

He gave a case from his own team. Bun's tests are written in TypeScript, which he described as independent of the language Bun runs in. So the team could run the same tests on both the old and new versions. Claude Code's tests are also in TypeScript. As transcribed, Sumner said they would have to be ported, and the excerpt does not explain why the two cases differ. He argued that once you rewrite the tests, "you can't really trust the tests anymore." He called that too risky. So the team sped up JavaScript itself instead of moving Claude Code to Rust.

For the compiler project, he said the team could run Bun's existing test suite, plus WebKit's tests, Test262 and Claude Code's tests. He explained why this mattered: "they're things that predated the project, so that way we know that the agent couldn't have messed with it."

He added a warning. It is easy to fool yourself that a test is finding bugs when it is not, so you must check that the tests really catch things.

Why it matters

Our reading: agents make code cheap to produce, so the scarce thing becomes proof that the code works. A test suite built before the agents arrived is independent of them. That makes it an asset worth counting, not just a maintenance burden.

For leaders weighing a rewrite, this changes the first question. Before asking which language or framework is better, ask which independent checks would carry over. If the tests must be rewritten too, the rewrite gives up a check Sumner's team largely trusted.

It also suggests a question for buyers. When a vendor says its code is agent-written and well tested, ask who wrote the tests, and when.

The other side

Sumner spoke from one project, built by a team that knows its own tooling well. The episode does not show whether a company with a thin or messy test suite could get the same result.

He also said his team wrote a lot of new tests and used fuzzing, which feeds a program many varied inputs to find bugs. So old tests were an anchor, not the whole defence. And a legacy suite only helps if it really catches problems, which he said you must verify.

Written by the WebPulse Newsroom with AI assistance, and checked by our editorial review: every quotation was verified against the recording's transcript. How we use AI.

The conversation this talking point comes from