Work

MultiFileTest: A Multi-File-Level LLM Unit Test Generation Benchmark and Impact of Error Fixing Mechanisms

Year: 2026
Type: conference-paper
Abstract: Unit test generation has become a promising and important use case for Large Language Models (LLMs).However, existing evaluation benchmarks for LLM unit test generation primarily focus on function-or class-level code (single-file) rather than on more practical, challenging multi-file codebases.To address this limitation, we propose MultiFileTest, a multifile-level benchmark for unit test generation covering Python, Java, and JavaScript.Mul-tiFileTest features 20 high-quality, moderatesized projects per language.We evaluate eleven frontier LLMs on MultiFileTest, and the results show that most tested LLMs exhibit moderate performance on MultiFileTest, highlighting the benchmark's inherent difficulty.We also conduct a thorough error analysis, which shows that even advanced LLMs, such as Gemini 3.0 Pro, exhibit basic yet critical errors, including executability and cascade errors.Motivated by this observation, we further evaluate these frontier LLMs under manual error-fixing and selferror-fixing scenarios to assess their potential when equipped with error-fixing mechanisms.Our dataset is available at MultiFileTest.Model CR ER LC BC #Tests #Correct Python GPT-4 Turbo 52 (-22) 70 (-30) 39 (-26) 35 (-24) 8.85 4.55 GPT-3.5 Turbo 52 (-12) 75 (-25) 45 (-18) 39 (-18) 14.15 8.20 OpenAI o1 67 (-22) 70 (-30) 60 (-28) 58 (-28) 35.50 24.35 GPT-5 Mini 66 (-17) 70 (-30) 61 (-22) 59 (-21) 12.85 9.20 Gemini 2.0 Flash 47 (-14) 60 (-40) 45 (-26) 42 (-26) 34.95 17.40 Gemini 3.0 Pro 91 (+1) 95 (-5) 87 (-4) 85 (-3) 24.45 22.15 Claude 3.5 Sonnet 86 (-6) 90 (-10) 67 (-7) 63 (-7) 18.00 15.55 CodeQwen1.5 22 (-24) 60 (-40) 41 (-29) 37 (-28) 25.15 6.25 DeepSeek-Coder 18 (-35) 35 (-65) 20 (-40) 18 (-36) 4.30 1.45 CodeLlama 0 (-31) 5 (-95) 5 (-56) 5 (-51) 3.90 0.00 CodeGemma 8 (-28) 25 (-75) 14 (-40) 13 (-36) 9.15 0.70 Java GPT-4 Turbo 43 (-16) 55 (-45) 26 (-14) 18 (-14) 6.40 2.80 GPT-3.5 Turbo 17 (-37) 25 (-75) 11 (-25) 12 (-15) 6.90 1.05 OpenAI o1 68 (+4) 85 (-15) 58 (-7) 54 (-2) 15.60 10.10 GPT-5 Mini 61 (-10) 70 (-30) 47 (-13) 45 (-7) 9.15 6.65 Gemini 2.0 Flash 31 (-25) 40 (-60) 29 (-25) 24 (-29) 22.65 7.15 Gemini 3.0 Pro 67 (-0) 75 (-25) 61 (+1) 57 (+2) 13.90 11.45 Claude 3.5 Sonnet 55 (-19) 70 (-30) 39 (-21) 31 (-22) 10.95 6.70 CodeQwen1.5 5 (-55) 5 (-95) 0 (-42) 0 (-31) 12.60 0.05 DeepSeek-Coder 13 (-39) 20 (-80) 5 (-28) 2 (-17) 1.35 0.25 CodeLlama 0 (-36) 0 (-100) 0 (-25) 0 (-20) 1.30 0.00 CodeGemma 2 (-55) 5 (-95) 3 (-34) 0 (-22) 1.75 0.05 JavaScript GPT-4 Turbo 70 (-19) 85 (-15) 48 (-27) 35 (-24) 8.35 6.35 GPT-3.5 Turbo 64 (-10) 75 (-25) 40 (-18) 30 (-15) 9.70 5.00 OpenAI o1 54 (-37) 65 (-35) 47 (-45) 38 (-41) 20.30 12.25 GPT-5 Mini 85 (-5) 90 (-10) 85 (-9) 70 (-12) 19.35 17.30 Gemini 2.0 Flash 75 (-1) 85 (-15) 71 (-17) 65 (-15) 40.95 28.65 Gemini 3.0 Pro 79 (-10) 75 (-25) 79 (-9) 75 (-8) 36.3029.25 Claude 3.5 Sonnet 74 (-13) 80 (-20) 60 (-17) 53 (-15) 18.05 13.35 CodeQwen1.5 55 (+23) 95 (-5) 66 (+31) 52 (+25) 26.10 15.50 DeepSeek-Coder 14 (-53) 35 (-65) 15 (-43) 10 (-33) 2.90 1.00 CodeLlama 9 (-53) 35 (-65) 7 (-37) 5 (-23) 7.15 0.55 CodeGemma 31 (-27) 60 (-40) 29 (-21) 21 (-17) 10.85 3.05 Model
Language: English
Subfield: Software
Open Access status: hybrid
OpenAlex ID: W4407359146
FWCI: 12.8
Cites:
Cited by: 2
Related to: 10