MBAug: Metamorphic BERT-Based Augmentation for Improving Deep Learning-Based Fault Localization Without Test Oracles

Anlin Hu, Wenjiang Feng, Xudong Zhu, Junjie Wang, Hua Liao, Qinfeng Chen · 2025

Deep Learning-based Fault Localization (DLFL) uses metamorphic testing to locate faults in the absence of test oracles. However, these approaches often face the issue of class imbalance, where the violated data (minority class) is significantly less than the non-violated data (majority class). To address this challenge, we propose MBAug: Metamorphic Bert-based Augmentation for improving DLFL without test oracles. MBAug combines metamorphic testing and BERT to generate the data of minority class and acquire class balanced data. We apply MBAug to two state-of-the-art DLFL baselines without test oracles, and the results show that MBAug significantly outperforms all the baselines in the absence of test oracles. This work provides a generalizable solution for class imbalance challenges in test oracle-free scenarios, advancing intelligent software engineering practices.

Read the paper · More papers on PaperTik