摘要
A new method called EPDG-GA which utilizes the Edge Partitions Dominator Graph (EPDG) and Genetic Algorithm (GA) for branch coverage testing is presented in this paper. First, a set of Critical Branches (CBs) are obtained by analyzing the EPDG of the tested program, while covering all the CBs implies covering all the branches of the Control Flow Graph (CFG). Then, the fitness functions are instrumented in the right position by analyzing the Pre-Dominator Tree (PreDT), and two metrics are developed to prioritize the CBs. Coverage-Table is established to record the CBs information and keeps track of whether a branch is executed or not. GA is used to generate test data to cover CBs so as to cover all the branches. The comparison results show that this approach is more efficient than random testing approach.
- 出版日期2009
- 单位厦门大学