IMPLEMENTATION OF McCABE’S METRICS
To measure the given software implementation using McCabe’s metrics and test it by
path testing method.
1. Test strategy
Scope of testing
To test the path of implementation using McCabe’s metrics.
To test the measurements of the given program using C language.
• the cyclomatic complexity using the formula
Tools used win runner & C programming.
2. Test plan
It is a document to say what to test, when to test, how to test, who to test.
• What to test- cyclomatic complexity using
• How to test-by using Win Runner.
• who to test- Developer.
3. Test bed- Win Runner and C programming language.
Step1: Draw a flow chart for given software implementation (to find greatest of 3
Step2: Draw a flow graph for the program from the flow chart.
Step3: Count the no of edges (e) and no of nodes (n) and regions(r).
Step4: Find the cyclomatic complexity using the formula
MCCABE’S METRICS FLOWCHART:
If a >b If b>a
b is grater c is grater
a is grater
TEST RESULT ANALYSIS:
Step1: Initialize the win runner
Start programs win runner win runner
Step2: Create a new html document to be tested and save it on the desktop
Step3: In win runner create a new task
Step4: Click on record button and open the saved html file
Step5: Then click on stop button the file will be recorded automatically
Step6: Then click on the button Run from top,
This will automatically give the test result as
Pass: If executed with out errors
Fail: If executed with some errors
And the execution time will also be displayed
Step7: Then go to Tools GUI Map Editor
And save the file at some location say for example “desktop”.
Once the test meets the exit criteria the activities such as capturing the key output
lessons learned result,logs,documents related to the project are achieved and used as
reference for next project .