Test case prioritization (TCP) is aimed at finding an ideal ordering for executing the available test cases to reveal faults earlier. To solve this problem greedy algorithms and meta-heuristics have been widely investigated, but in most cases there is no statistically significant difference between them in terms of effectiveness. The fitness function used to guide meta-heuristics condenses the cumulative coverage scores achieved by a test case ordering using the Area Under Curve (AUC) metric. In this paper we notice that the AUC metric represents a simplified version of the hypervolume metric used in many objective optimization and we propose HGA, a Hypervolume-based Genetic Algorithm, to solve the TCP problem when using multiple test criteria. The results shows that HGA is more cost-effective than the additional greedy algorithm on large systems and on average requires 36% of the execution time required by the additional greedy algorithm.
2. fault
test case
Test Case Prioritization
Find an ideal sorting for executing test cases in order to reveal faults earlier
3. fault
test case
Test Case Prioritization
No a priori information
about faults
Find an ideal sorting for executing test cases in order to reveal faults earlier
4. fault
test case
Test Case Prioritization
No a priori information
about faults
Use of surrogates
Find an ideal sorting for executing test cases in order to reveal faults earlier
5. branch
test case
Test Case Prioritization
No a priori information
about faults
Use of surrogates
Find an ideal sorting for executing test cases in order to reveal faults earlier
6. statement
test case
Test Case Prioritization
No a priori information
about faults
Use of surrogates
Find an ideal sorting for executing test cases in order to reveal faults earlier
7. statement
test case
Test Case Prioritization
No a priori information
about faults
Use of surrogates
Find an ideal sorting for executing test cases in order to reveal faults earlier
NP-Complete problem
8. statement
test case
Test Case Prioritization
No a priori information
about faults
Use of surrogates
Find an ideal sorting for executing test cases in order to reveal faults earlier
NP-Complete problem
Approximation
algorithms
22. Multi Objective Metaheuristics
Bad effectiveness as the
problem dimensionality
increases
For more than 3-objectives, all
individuals are non-dominated
Poor Selective Pressure
23. Multi Objective Metaheuristics
Bad effectiveness as the
problem dimensionality
increases
No strong empirical evidence
of the cost-effectiveness with
respect to simpler heuristics
For more than 3-objectives, all
individuals are non-dominated
Poor Selective Pressure
25. Hypervolume
In many-objective optimization there is a growing trend to solve many-
objective problems using quality scalar indicators to condense multiple
objectives into a single objective.
Auger et al. - Theory of the hypervolume
indicator: optimal distributions and the
choice of the reference point - FOGA 2009
26. Hypervolume
In many-objective optimization there is a growing trend to solve many-
objective problems using quality scalar indicators to condense multiple
objectives into a single objective.
Auger et al. - Theory of the hypervolume
indicator: optimal distributions and the
choice of the reference point - FOGA 2009
The hypervolume measures the quality of a set of solutions as the total
size of the objective space that is dominated by one (or more) of such
solutions.
37. Research Questions
RQ1 : What is the cost-effectiveness of HGA, compared to
cost-aware additional greedy algorithms?
Cost-cognizant Average Fault Detection Percentage (AFDPc)
38. Research Questions
RQ1 : What is the cost-effectiveness of HGA, compared to
cost-aware additional greedy algorithms?
Cost-cognizant Average Fault Detection Percentage (AFDPc)
RQ2 : What is the efficiency of HGA, compared to
cost-aware additional greedy algorithms?
Execution time (in seconds)
42. Results RQ1
Program 2-Objective 3-Objective
p-value Â12 magnitude p-value Â12 magnitude
bash < 0.01 0.88 Large < 0.01 0.95 Large
flex < 0.01 0.70 Medium < 0.01 0.75 Large
grep < 0.01 0.85 Large < 0.01 0.85 Large
printtokens 1 0.10 Large 1 0.10 Large
printtokens 2 1 0.30 Large 0.73 0.40 Small
sed < 0.01 0.85 Large 0.01 0.80 Large
43. Average Execution Time
2-Objective formulation
Results RQ2
0
1000
2000
3000
4000
5000
6000
7000
8000
9000
bash flex grep printtokens printtokens2 sed
Additional Greedy 2Obj HGA 2Obj
seconds
53. FutureWork
Incorporate diversity as a testing criteria
Apply HGA for other test case
optimization problems
Investigate the scalability
for up than 3 testing criteria
Comparison among additional greedy algorithm, 2-optimal greedy, hill climbing and genetic algorithms
Comparison among additional greedy algorithm, 2-optimal greedy, hill climbing and genetic algorithms
Comparison among additional greedy algorithm, 2-optimal greedy, hill climbing and genetic algorithms
Comparison among additional greedy algorithm, 2-optimal greedy, hill climbing and genetic algorithms
Comparison among additional greedy algorithm, 2-optimal greedy, hill climbing and genetic algorithms
Hundreds of orderings representing trade-offs in the measures space
Hundreds of orderings representing trade-offs in the measures space
Hundreds of orderings representing trade-offs in the measures space
Hundreds of orderings representing trade-offs in the measures space
The Hypervolume Indicator is a generalization of previously used cumulative scores
A candidate test case ordering corresponds to a set of monotonically increasing cumulative scores
Welch's t-test p-values of the hypothesis HGA > Additional Greedy