OO Regression Testing

Ye Wu and Mei-Hwa Chen and Ming-Hung H. Kao


Regression testing is an important activity at both testing and maintenance phases. It is desirable to use minimum effort, yet preserve the quality of the software when a modification is made to it and regression testing is taking place. Much work has been proposed to aid an effective regression testing, whereas very few studies address regression testing in an object-oriented paradigm. In this paper, we present a regression testing technique for object-oriented programs. The technique takes both static function dependence information and dynamic execution sequence into account. We construct a Function Dependence Graph (FDG) for the program to obtain the static function dependence relationship among methods in the program. In the runtime, for each test case, we use a Function Calling Graph (FCG) to record the calling sequence. Once modifications have been made to the program, this technique locates the modified methods and identifies affected methods based on FDG. A test case will be included in the regression test suite if it contains at least one behavior-affected function in its FCG. A method is considered as behavior-affected if it functionally depends on the modified method and it has an influence on the behavior of the program. To compare the effectiveness of this technique with other existing approaches, we conducted an empirical study on an industrial real-time system. The results show that not only does this technique preserve all the necessary information for regression testing, but it is also much more efficient than the existing techniques.