Fault localization produces bug positions as the basic input for many automated program repair (APR) systems. Given that test cases are the common means that automatic fault localization techniques leverage, we investigate the impact of their characteristics (in terms of quality and quantity) on APR. In particular, we analyze the statements that appear in crash stack traces when test cases fail (note that stack traces are available when an ordinary test case fails since its verdict is often made by assertions that produce errors such as AssertError in Java and JUnit), and explore the possibility of using some relevant crash information to enhance fault localization; this ultimately improves the effectiveness of APR tools. Our study reveals that the considered state-of-the-art APR systems achieve the best performance when fixing bugs associated with boolean type expected values (e.g., assertTrue ()) or assertFalse(). In contrast, they achieve their worst performance when addressing bugs related to null check assertions. Meanwhile, null check bugs as well as the bugs associated with boolean and string type expected values are still the main challenge that should be addressed by the future APR. For exception throwing bugs, existing APR systems present the best performance on fixing NullPointerException bugs, while the tough task of them is to resolve the bugs throwing developer-defined exceptions. The information in stack traces after executing the bug-triggering test cases can be used to effectively improve the performance on fault localization and program repair.
CITATION STYLE
Zhang, J., Liu, K., Kim, D., Li, L., Liu, Z., Klein, J., & Bissyande, T. F. (2021). Revisiting Test Cases to Boost Generate-and-Validate Program Repair. In Proceedings - 2021 IEEE International Conference on Software Maintenance and Evolution, ICSME 2021 (pp. 35–46). Institute of Electrical and Electronics Engineers Inc. https://doi.org/10.1109/ICSME52107.2021.00010
Mendeley helps you to discover research relevant for your work.