TestExplora: Benchmarking LLMs for Proactive Bug Discovery via Repository-Level Test Generation
Abstract
Lay Summary
Problem. Software bugs that reach real users can cause serious damage—lost data, outages, and costly failures. People are starting to use AI models to automatically write tests that catch bugs, but today's benchmarks only check whether LLM can confirm code already works or recreate bugs humans have already found. What we actually want is that LLM can spot unknown bugs hiding in a codebase before they cause harm. Solution. We built TestExplora, a benchmark with 2,389 testing tasks from 482 real GitHub projects. Instead of telling the models where the bug is, we give it only the documentation describing what the code is supposed to do, and ask it to write tests that reveal where the code falls short. A test only counts as successful if it catches the real bug. We also designed the benchmark to refresh itself with newly fixed bugs over time, so models can't simply memorize the answers.