Revesery
Dashboard
Home
Explore
Groups
Add bookmarks
Revesery
HomeExploreTrendingGroupsContributors
⌘K

Most read

ShareLogin
Back to feed
AR
Alex RuiezExpert
@alex · Sep 29, 2026 · 8 views
#Tools

How to Keep AI Agents From Writing Their Own Tests

Your CI went green and production still broke. That is the trap when an autonomous agent writes the tests your pipeline runs: the same bug slipped past it twice, and the suite kept saying everything was safe.

The fix is short, and it came out of half an hour of thinking about it. Put the eval contract first and the agent second — the golden outputs and the assertions sit outside the agent, and the agent only adds new tests while the old ones stay green.

Tutorial

  1. Lock the golden outputs and the assertions outside the agent. Write them yourself and keep them where the agent cannot edit them.
  2. Let the agent add new tests only while the existing tests stay green. If an old test is failing, nothing new gets added until it passes again.

Wrapping Up

Two rules, and the order carries most of the weight: contract first, agent second. With the assertions out of the agent's hands, the next test it writes has to earn its place against the ones you already trust.

Liked Alex Ruiez's share? Revesery is where people swap what they're actually building.

Join with Google
Be the first to sayBe first

Does this still work?

Nobody's checked yet

Sign in to tell everyone how it went.

Continue with Google

Be the first — one tap saves the next person an hour.

It takes 3 reports in 30 days to set the status.

Comments

Join the conversation — sign in to comment.

Sign In Now

No comments yet — start the conversation!

More shares you might like

NewsBuzz from Block: Open-Source Slack for Humans and AgentsAlex Ruiez · 2h · 6 viewsNewsFree Course Explains AI Agent Harness EngineeringAlex Ruiez · 2h · 8 viewsAIClaude Code Made a 30-Second Promo Video From Two LinksAlex Ruiez · 2h · 7 viewsToolsHow to Plan a Coffee Crawl in MadiunAlex Ruiez · 2h · 7 viewsAIHow to Claim 1 Month of Cue Plus for FreeAlex Ruiez · 2h · 8 viewsToolsHow to Make ASMR Food Videos With ChatGPT + Google FlowAlex Ruiez · 2h · 7 views

Site footer

Revesery

Empowering people to share valuable insights, discover hidden information, and connect with an amazing community of learners and experts.

  • 455Members
  • 591Shares published

Explore

  • Explore shares
  • Trending now
  • Top contributors

Company

  • About us
  • Editorial policy
  • Contact
  • Advertise with us
  • System status
© 2026 Revesery
  • Privacy
  • Terms
  • Trust & Safety
  • DMCA
HomeExploreShareProfile
LiveCOChinedu Olihjoined Revesery· 5 hours ago