An approach to incremental testing
Mary Jean Harrold, Mary Lou Soffa · 1988
Reanalysis and retesting of modified software are major factors contributing to the high cost of development and maintenance of software systems. In large systems with many modules (each containing one or more procedures), changes must be incorporated into the system and then tested in an efficient way. Incremental compilers provide assistance in quickly incorporating the changes into the code. Any change that is made to the module necessitates testing of the changed module. However, current tools do not support the incremental testing of modified programs with the same level of precision as incremental compilers. Efficiency in retesting a module can be increased by reusing some of the information that was obtained during the previous validation of the module, sharing information gathered by other software tools, and reducing the number of test cases that are run. These approaches for improving efficiency were used to design the incremental testing system that is described in this dissertation. Information that is gained during a testing session is saved and reused during the next session. This consists of the results of the analysis to determine what is to be tested and the actual test cases that were used to validate the module. Then, in response to a change in the validated module, the incremental tester reuses the analysis information to determine which parts of the module must be (re)tested and which new or existing test cases must be rerun. In order to accommodate procedures, an existing intraprocedural data flow testing methodology is extended to provide interprocedural testing and then adapted to handle incremental changes. Since the testing is based on data flow, updated data flow information is required by the tester. At the intraprocedural level, existing tools provide data flow analysis information to locate definitions and uses of variables. However, to test the definitions and uses that reach across procedure boundaries, precise interprocedural data flow analysis techniques were developed that compute the interprocedural du/ud-chains. This information can be shared by other tools in the environment. The incremental tester aids in the reducing the number of test cases that must be (re)run by identifying the parts of the program that must be retested. Validation of the changed module is achieved by retesting only the parts of the module that are changed or affected by the change. Savings is realized in the time required to perform the analysis, the time to generate test cases, and the time to reexecute the module with the test cases.