Automatic Test Path Generation from Sequence Diagram Using Genetic Algorithm
Paper ID : 1101-IST
1Bahareh Hoseini, 2Saeed Jalili *
1Tarbiat Modares University
2Tarbiyat modares University
Software testing is an important and complicated phase of software development cycle. Software test process acquires test cases as input for the system under test to evaluate the behavior of the product. White box testing requires a set of predefined test paths to generate test cases, therefore generating a set of reliable test paths is a critical task. The most common approach in white box testing is to generate test paths from source code while the generation process must be delayed until completion of source code. Using sequence diagram, as the input artifact for generating test path is cost and time efficient due to the fact that test process starts before implementation phase and tester involvement in source code complexity is reduced to a minimum. Test paths are generated from the control flow graph, which is extracted from sequence diagrams. Among all graph based coverage, Prime path coverage subsumes different graph based coverage criteria that lead us to complete path coverage. Also, prime path coverage concentrates on visiting all nodes and edges in the control flow graph rather than traversing all existing paths, which results in test effort reduction. Genetic algorithm is applied minimize number of test cases required to reach the complete coverage. In this paper, we proposed a method to generate all prime paths automatically and extract minimum paths with shortest possible length, which covers all prime paths by using genetic algorithm. The experimental results show complete prime path coverage results with the least number of test paths.
genetic algorithm, test path generation, sequence diagram, prime path coverage