Title: Selecting Test and Identifying Test Coverage Requirement for Modified Software
1Selecting Test and Identifying Test Coverage
Requirement for Modified Software
- Author G.Rothermel and M.J Harrold
- Source International Symposium on Software
Testing and Analysis Proceedings of the 1994 ACM
SIGSOFT international symposium on Software
testing and analysis - Presented by Chen Hung-Hsiang
2Progress
- G.Rothermel and M.J.Harrold , "Analyzing
Regression Test Selection Techniques," IEEE
Transaction on Software Engineering,August 1996 - Regression selection techniques
- Linear Equation (intra)
- Symbolic execution
- Data Flow
- Modification Based
- Cluster identification
- Graph Walk
- Linear Equation(inter)
- Path analysis
- Program Dependence Graph
- Firewall
- Slicing
- Modified entity
CDG?PDG?SDG
3Outline
- Introduction
- Background
- PDG
- IntraProcedural Regression Testing
- InterProcedural Regression Testing
- Conclusion
4Introduction
- Coverage problem
- Coverage techniques use structural coverage
criteria to select existing tests that exercise
changed or affected program components. - Safe technique problem
- Safe techniques, which select every test that
will cause a modified program to produce
different output than its original version. - Author present an approach to regression testing
that handles two important tasks - selecting tests from the existing test suite that
should be rerun - identifying portions of the code that must be
covered by tests.
5Introduction
- Solution
- Deal with individual procedure
- Use Program Dependence Graph
- Deal for groups of procedure or entire programs
- Use System Dependence Graph
- Advantages
- Safe and more precise selects technique
- identify test coverage requirement
- Handles structural and nonstructural program
modifications, and processes multiple
modification with a single application of the
algorithm
6What is PDG?
7(No Transcript)
8(No Transcript)
9(No Transcript)
10(No Transcript)
11(No Transcript)
12(No Transcript)
13Background
- Terminology
- Control dependence edge
- cd-predecessor
- cd-successor
- Data dependence edge
- dd-predecessor
- dd-successor
14Background
dd-predecessor
cd-predecessor
15IntraProcedural Regression Testing
16IntraProcedural Regression Testing
17IntraProcedural Regression Testing
18IntraProcedural Regression Testing
Form O(n2) to O(n3)
19IntraProcedural Regression Testing
20IntraProcedural Regression Testing
R5
both R2,R3 history is T2
21IntraProcedural Regression Testing
Data dependence edge
22IntraProcedural Regression Testing
- Find set of affected definition-use pairs in G
- Every du-pair(S1,S2) in P has a corresponding
data dependence edge (N1,N2) in G. - (1)N1 is new or modified
- (2)N2 is new or modified
- (3)N1 is control or data dependent on some other
new or modified node.
23IntraProcedural Regression Testing
Type 1 and 3
Type 2
24InterProcedural Regression Testing
- Edges defined
- 1.Control dependence edges
- 2.Intraprocedural data dependence edges
- 3.Parameter control dependence edges
- 4.Parameter-in edges
- 5.Parameter-out edges
- 6.Call edges
- 7.Interprocedural dependence edges
- 8.Transitive dependence edges
25InterProcedural Regression Testing
26InterProcedural Regression Testing
27InterProcedural Regression Testing
28Conclusion
- Algorithm selects those tests from an existing
test suite that may exhibit different output in
the modified program - It identifies parts of the program that are
affected by modifications and should be covered. - The algorithm handles multiple changes, does not
require prior knowledge of the location of
changes, and works on both single procedures and
entire programs.