Home
About Us
Advertise
Contact Us
Email
Search:    
Hot Articles
 
Get the Latest Posts Delivered to You
Through E-mail
 
 
 
Download Consolidated Study Material for Certification Exams Like
 
 
Understanding the Graph Matrix Based Testing

In graph matrix based testing, we convert Our flow graph into a square matrix with one row and one column for every node in the graph. If the size of graph increases, it becomes difficult to do path tracing manually.


Objective of the Tutorial:
To trace all links of the Flow Graph at least once, draw a Square Matrix from it & find out the cyclomatic complexity, V(G) and hence the independent paths.

Process of constructing the Square Matrix leading to computation of Cyclomatic Complexity goes like this:

Step – 1: Start from the following basic Flow Graph as an example of an input


Step – 2: Construct its corresponding Square Matrix


Step – 3: Let us consider another Flow Graph as an example



Step – 4: Construct its corresponding Square Matrix


It may be noted that if there are several links between two nodes then " + " sign denotes a parallel link.

This is, however, not very useful. Hence we assign a weight to each entry of the graph matrix.

We use '1' to denote that the edge is present and '0' to indicate its absence. Such a matrix is known as a connection matrix.

For above figure connection matrix can be shown as under.



Step – 5:
Compute it's V(G) & draw the matrix again for the same



i.e., we sum each row of the above matrix. Then, we subtract "1" from each row. We, then, add this result or column of result and add "1" to it.

This gives us V(G).

For above matrix we get V(G) = 2.



Most Popular Articles on White Box Testing:

All about White Box Testing

Approaches to Code Complexity Testing - Cyclomatic Complexity

Comparison among Black Box & White Box Testing Techniques

Check Your Skills on White Box Testing - Through Descriptive Questions 


Please click here  -  To read more Articles & Tutorials
on White Box Testing



If you want to keep track of further articles on Software Testing, I suggest you to subscribe my RSS feed.

You can also Subscribe by E-mail
and get All New articles delivered directly to your Inbox.

 

Comments :


Leave Your Comments: (*) Marked Fields are Mandatory

Name *
 
Email Address *
 
Website
 
Speak your mind
 
  Subscribe
 
Sign up to receive daily updates
either via email or RSS!
   
Advertise Here
Advertise Here
Please use Vertical Scroll Bar
to View More Categories
 
 
     
 
 
advertise | privacy policy | copyright policy | online conduct home | about us | glossary | contact us | blog | email
Copyright © 2010. softwaretestinggenius.com. All Rights Reserved.
Website Designed & Developed By: 3dee Technologies