- The paper presents a novel benchmark that mines Java repositories and verifies test-code co-evolution through a robust three-phase pipeline.
- It evaluates state-of-the-art agents, achieving 77.5% success in test generation and 74.6% in test update while exposing harness fragility challenges.
- The benchmark emphasizes the need for dynamic, execution-based assessments to enhance test maintenance, supporting future expansion to more languages and models.
TestEvo-Bench: An Executable, Live Benchmark for Test and Code Co-Evolution
Introduction
TestEvo-Bench introduces a significant advancement in the benchmarking of test-code co-evolution tasks, directly addressing the need for data-driven, execution-grounded evaluation of automated agents that generate or update regression tests in response to software changes. Unlike prior datasets that often rely on static heuristics or metadata, TestEvo-Bench grounds its tasks in real repository history, verifies execution, and tracks precise behavioral relationships between code modifications and associated test edits. This benchmark uniquely enables researchers to assess whether test generation and update agents genuinely reason about the propagation of software behavior changes.
Figure 1: TestEvo-Bench is constructed through a three-phase mining, cleaning, and task construction pipeline.
Benchmark Construction and Design
TestEvo-Bench is constructed via a meticulous three-phase pipeline: repository mining, execution-backed data cleaning, and robust task construction.
- Mining Phase: The benchmark mines open-source Java Maven repositories, filtering for projects with stable build and execution properties. Commit-pairs are selected where both code and test changes co-occur, retaining only high-quality candidates validated via dynamic dependency analysis.
- Execution-Backed Cleaning: Each candidate is rigorously rebuilt and tested across revision pairs. Only those changes that yield executable, semantically meaningful code/test co-evolution pairs are retained. Aggressive filtering discards any tasks lacking a clear behavioral tie between the test and the code change, or where reproducibility is impaired.
- Task Construction: Validated co-evolution instances are formed into benchmark tasks for either test generation (requiring tests that exercise newly introduced software behavior) or test update (demanding updates to failing tests such that they pass with the changed code). Each task is annotated with fine-grained metadata and anchored to real revision timestamps.
Figure 3: Three-phase mining pipeline used to build TestEvo-Bench: repository-level filtering, commit-level filtering with runtime dependency mapping, and test-level identification of code/test co-evolution triples.
This approach ensures that every benchmark task is strictly executable, fully contextualized, and semantically non-redundant. The datastream is "live": new tasks are regularly harvested, enabling contamination-aware evaluation (i.e., assessments that respect model training cutoffs by filtering out potentially leaked tasks).
Figure 4: TestEvo-Bench task counts across time-segmented subsets. Each bar reports the number of tasks whose new revision falls in the corresponding half-year; the Older subset combines all tasks before 2015.
Experimental Setup and Metrics
TestEvo-Bench evaluates four state-of-the-art agents combining leading code-editing harnesses (Claude Code, Gemini CLI, and SWE-Agent) with modern foundation models (Claude Opus 4.7 and Gemini 3.1 Pro). The benchmark covers two tracks:
- Test Generation: The agent must author new test cases capturing new code behavior. Success requires passing the new revision and failing (or not compiling) on the old revision—a strong test of semantic discrimination.
- Test Update: The agent modifies broken tests so they pass with changed code. Any patch achieving passing and correct compilation is valid, with no requirement to mimic the developer’s text exactly.
Performance is measured using execution-grounded metrics:
- Success Rate: Percentage of tasks where the agent produces a test passing on the new revision (and failing on the old, for generation tasks).
- Coverage: Proportion of changed code lines exercised by the test (collected via JaCoCo).
- Mutation Score: Share of artificial mutants killed by the test (using Universal Mutator), assessing the thoroughness of behavioral testing.
- Failure Modes: Redundant (non-discriminating) tests, execution failures, compilation failures, and harness failures are separately tracked.
Results and Analysis
Test Generation
The best harness-model compositions (Claude Code / Gemini CLI with their respective foundation models) reach 77.5% success rate on test generation. Redundant outputs—tests that pass before and after the change—remain substantial across all agents, reflecting the non-trivial challenge of producing genuinely discriminating oracles. The highest coverage on passed tests closely approaches that of human-authored tests (76.8% vs. 80.8%), with mutation scores suggesting that LLM-generated tests can match or outperform developer-written ones in killing code mutants in passing cases.
Test Update
For test update, top agents achieve a 74.6% success rate. Coverage on passing tasks is again high (79.4%–79.1%), tightly approximating developer reference. Notably, harness failures are a significant limiting factor for some agent configurations, especially the academic SWE-Agent, revealing driver/model interface fragility.
Figure 5: Success across time-segmented subsets for (a) test generation and (b) test update. Subsets with fewer than 20 methods are omitted to suppress small-sample noise.
Temporal and Cost Analysis
Performance declines visibly on recent tasks for test generation, highlighting ongoing risks of training set leakage and dataset shift. Test update appears temporally more stable. When imposing tighter cost budgets per task, success rates drop sharply—most dramatically for Claude Opus 4.7-based agents—which underlines the urgent need for more cost-efficient agentic design for practical, routine deployment.
Figure 6: Empirical CDF when per-task cost is limited. Top row: test generation; bottom row: test update. Vertical dashed lines mark per-task budget caps at \$3 (red), \$1 (green), and \$0.5 (blue); the annotated ``\% kept'' is the fraction of tasks whose default-budget cost stays at or below each cap.
Implications and Future Developments
TestEvo-Bench underscores several important findings:
- Current SOTA agents remain far from saturating these tasks; success rates drop on recent commits and with practical compute constraints.
- Agent reliability is strongly sensitive to harness quality and model-harness interoperation, as evidenced by high harness failure rates outside of industrial agent/model pairings.
- Not all LLM-produced tests offer the intended discriminative power; high rates of redundant tests reveal limitations in test-oracle reasoning.
Practically, the benchmark offers an immediate vehicle for transparent, reproducible assessment of coding agents for regression test generation and maintenance. Theoretically, it highlights the persistent gap between shallow code-diff-based label heuristics and true behavioral change comprehension—emphasizing the value of execution-based, dynamic labels for future learning.
Looking forward, principal directions include: expanding to additional languages and build systems (especially Python and JavaScript), supporting wider model harness coverage (including open-source models), and optimizing the infrastructure for efficient, public-facing execution-based evaluation.
Conclusion
TestEvo-Bench comprehensively raises the bar for the evaluation of LLM-driven test maintenance and generation agents by requiring agents to faithfully reflect code/test co-evolution as it occurs in real repositories. Its executable, dynamically labeled benchmarks expose performance ceiling, model-capture artifacts, and interface fragility in existing systems, and provide an essential basis for continued progress in agentic software engineering. The live, continually growing corpus and contamination-aware subsets ensure it will remain relevant as models and agents evolve. TestEvo-Bench is publicly available with infrastructure and leaderboard at https://www.testevo-bench.com.