What's your strategy for getting AI to test actual messy edge cases instead of happy paths?
by•
When you ask an AI to write tests for a complex module it always defaults to the cleanest, most basic inputs. It never thinks about null values, weird timeouts or race conditions unless you hold its hand through every single scenario.
By the time I write out all the strict edge cases myself it almost feels faster than letting the agent do it.
How do you structure your prompt to make the AI think like a QA engineer trying to break the code rather than just covering lines of code?
7 views
Replies
some of the things that I usually do:
-the agent wrote the code shouldn't write the tests. give a brand-new agent only the spec and ask it to break it instead
-personas help, for ex: “you’re a tired user on bad wifi who double-taps everything”
-make eval harness with a human write the test cases with a hidden split, change one thing at a time.