Subscribe by Email


Tuesday, May 15, 2012

How does a DU path segment play a role in data flow testing?


Whenever you would have came across the topic of data flow testing, you surely would have heard about the term “du path segment” but still not familiar with it! This article if focussed up on the du path segments and what role it has got to play in the data flow testing. 
We will discuss the du path segments under the context of data flow testing and not as a separate topic so that it becomes easy for you to understand. 
The whole process of data flow testing is guided by a control flow graph that apart from just guiding the testing process also helps in rooting out the anomalies present in the data flow. With all the anomalies being already discovered one can now design better path selection strategies taking in to consideration these data flow anomalies. 

There are nine possible anomalies combinations as mentioned below:
  1. dd: harmless but suspicious
  2. dk: might be a bug
  3. du: a normal case
  4. kd: a normal situation
  5. kk: harmless but might be containing bugs
  6. ku: a bug or error
  7. ud: not a bug because of re- assignment
  8. uk: a normal situation
  9. uu: a normal situation
For data flow testing some data object states and usage have been defined as mentioned below:
1.      Defined, initialized, created à d
2.      Killed, undefined, unreleased àk
3.      Used for:
(a)    Calculations à c
(b)   Predictions à p

Terminology associated with Data Flow Testing


Almost all the strategies that are implemented for the data flow testing are structural in nature. There are certain terminologies associated with the data flow testing as stated below:
  1. Definition clear path segment
  2. Loop free path segment
  3. Simple path segment and lastly
  4. Du path

What is a DU path Segment?


- DU path segment can be defined as a path segment which is simple and definition clear if and only if the last link or node of the path has a use of the variable x.

Let us take an example to make the concept of du path segment clearer. 
- Suppose a du path for a variable X exists between two nodes namely A and B such that the last link between the two nodes consists of a computational use of the variable X. 
- This path is definition clear and simple. 
- If there exists a node C  at the last but one position that is the path is having a predicate use and the path from the node A to node C is definition clear and does not contain any loop. 
- Several strategies have been defined for carrying out the data flow testing like:
  1. ADUP or all du paths strategy
  2. AU or all uses strategy
  3. APU+ C or all p uses/ some c uses strategy
  4. ACU +P or all c uses/ some p uses strategy
  5. AD or all definitions strategy
  6. APU or all predicate uses strategy
  7. ACU or all computational uses strategy

Strategy for DU Path Strategy

We shall describe in detail here only the ADUP or all du paths strategy. 
- This strategy is considered to be one of the most reliable and strongest data flow testing strategy. 
It involves the use or exercising of all the du paths included in the definition of the variables that have defined to every use of the definition.
- All the du paths suppose to be a strong criterion for testing but it does not involve as many tests as it seems.
- Simultaneously many criterion are satisfied by one test for several definitions and uses of the variables.




No comments:

Facebook activity