iCreatAI News
Skip to content
Hacker News AI· BerislavLopac·· 2 days agoAI score58

Tests as data: Ensuring AI-generated code does what we want

Tests as data: Ensuring AI-generated code does what we want

AI summary

The author reports that developers at Thoughtworks distrust their tests because AI coding agents refactor both code and tests as features are added, and argues AI-generated tests are often voluminous, hard to read, coupled to implementation via mocks, and may confirm current behavior including bugs. He proposes customer tests written as data in a DSL (tables, structured scenarios, textual projections of UI and state) interpreted by a small test runner that AI can generate, drawing on Fit, Specification by Example, Go's tabular tests, and Approval Testing.

Source: Hacker News AI · martinfowler.com