Fine-grained approach to metamorphic slicing: Enhancing fault localization in the absence of oracle
Daixu Ren, Zheng Zheng, Huai Liu, Tsong Yueh Chen · Information and Software Technology · 2026
ABSTRACT Context : Fault localization suffers from the oracle problem, which hinders its widespread application in real-world scenarios. Through integrating the basic idea of metamorphic testing into debugging with slicing, metamorphic slicing has been proposed as an effective technique to address the oracle problem in the field. So far, there is only one suggestion to implement metamorphic slicing, which employs a simplistic weighting strategy for calculating the suspiciousness of each program statement, which may impair the effectiveness of fault localization. Objective : To improve the effectiveness of metamorphic slicing in fault localization, we investigate a fine-grained weighting approach that suggests distinct weighting strategies for statements covered by different types of test cases. Methods : By assigning greater weights to either the intersection or the symmetric difference of the statement sets covered by different test cases, we propose two emphasis strategies: the Intersection Emphasis Strategy and the Symmetric Difference Emphasis Strategy, respectively. Based on these strategies, we develop a series of variants for implementing metamorphic slicing. We conduct an empirical study to evaluate the effectiveness of these variants compared to the original metamorphic slicing technique based on nine object programs that are from different application domains and of varying sizes. Results : The empirical results show that our proposed fine-grained weighting approach can improve the effectiveness of metamorphic slicing in fault localization. In particular, we observe that the Symmetric Difference Emphasis Strategy achieves better fault localization performance, indicating that assigning greater weights to the differences in statements covered by different types of test cases leads to more effective fault localization. Conclusions : This study discloses a potential research direction for further enhancing the metamorphic slicing technique, and the variations in weightings provide valuable insights as well as clues for fine-tuning the method.