Showing posts with label Metrics. Show all posts
Showing posts with label Metrics. Show all posts

Wednesday, 28 December 2022

What is Defect Density?

 Quality is inversly proportional to defects.Software is tested based on various parameters like quality,performance,security,functionality and many more important parameters.Software developers must find the errors/defects and fix it before delivering it to clients.An early fix of the defect will reduce the cost marginally.In order to calculate quality of software developers use defect density.The process of defect detection ensures that the end product meets the client standards and needs.

 More Defects = Less Quality

Less Defects=More Quality.

Defect Density indicates the number of bugs found in the  software or product.

Steps to calculate Defect Density:

Defect Density= Average number of Defects/KLOC.

where KLOC is lines of code per thousands

Eg.

Module 1 = 10 bugs

Module 2 = 15 bugs

Module 3 = 10 bugs

Total bugs=10+15+10 =35


Lines of Code

Module 1 =1000

Module 2=2000

Module 3=500

Total Lines of Code= 1000+2000+500=3500


Defect Density = 35/3500 =.01 Defects/LOC = 10 Defects/KLOC.


Advantages:

1.Detect areas that need improvement.

2.Identify components of high risk.

3.Helps testers to estimate amount of testing required.

4.Understand quality of product.



Friday, 19 January 2018

Cyclomatic Complexity

Cyclomatic Complexity(Code Complexity) is a metric used to measure complexity of a program.
This metric was developed by Thomas McCabe in 1976.It measures the number of linearly independent paths through the programs code.
If the program's cyclomatic complexity is low , it will be easier to modify.

It can be defined by the following formula:

M = E - N + 2P

where,
     E - Number of Edges in the graph.
     N - Number of Nodes in the graph.
     P - Number of Connected Components.



Wednesday, 17 January 2018

Requirement Traceability Matrix

This document is very important to know the status of testing.This document captures all the requirements and traces the associated test cases to the requirement.The main purpose of this document is to see that all the functionalities have corresponding test cases.

Types of Traceability Matrix:
1.Forward Traceability:It checks  whether the project is progressing in desired direction.
It maps requirements to test cases.

2.Backward Traceability:It checks whether the current project remains on right track.
It maps test cases to requirements.