Software Quality Assurance: Defect Management and Metrics
Steps in Defect Management Process
Defect Prevention
Defects are prevented in the early stages of development. The main goal is to find and fix issues before they appear in later stages. Root cause analysis is done to stop similar defects from happening again.
Deliverable Baseline
When a software version is stable and ready for testing, it becomes the “baseline.” Future changes and tests are done based on this baseline.
Defect Discovery
Defects are found during testing. Steps:
- Find defect – Identify as early as possible.
- Report defect – Tester informs the development team.
- Acknowledge defect – Developer accepts and starts fixing it.
Defect Resolution and Improvement
Developers fix the defect according to its priority.
- After fixing, testers verify and ensure it is resolved properly.
- Process Improvement: Review the causes of defects and improve the testing or development process. Helps prevent similar defects in future projects.
The Defect Life Cycle
A defect life cycle is the process through which a software defect passes from the time it is identified until it is fixed and closed. It helps in tracking the status of a defect at every stage of the testing process.
- New: When a defect is first detected and reported, it is marked as New.
- Open: The defect is assigned to a developer for analysis and fixing. If it is not valid, it may be Rejected or Deferred for later.
- Fixed: After the developer resolves the issue, its status becomes Fixed.
- Retest: The tester rechecks the defect to verify whether it has been correctly fixed.
- Reopen: If the issue still exists or is not properly resolved, it is Reopened and sent back to the developer.
- Closed: Once the tester confirms that the defect no longer exists, the defect status changes to Closed.
The defect life cycle ensures proper tracking, communication, and management of defects, improving the overall software quality.
Defect Reporting
Defect reporting is the process of communicating defects or issues found during software testing to the development team. It helps developers understand, reproduce, and fix the problem quickly.
A Good Defect Report Should:
- Include all steps to reproduce the issue.
- Be clear, detailed, and well-written.
- Help the development team decide which defect to fix.
Main Activities under Quality Movement
- Quality Planning
- Establishing quality goals, standards, and processes.
- Defining responsibilities and resources needed for quality assurance.
- Quality Assurance (QA)
- Preventing defects by following process-oriented activities.
- Includes audits, process monitoring, and adherence to standards.
- Quality Control (QC)
- Detecting and correcting defects through product-oriented testing and inspection.
- Ensures the final software meets quality requirements.
- Process Improvement
- Continuously analyzing and refining development and testing processes.
- Uses techniques like CMMI (Capability Maturity Model Integration) and Six Sigma.
- Quality Measurement
- Collecting and analyzing data related to software quality.
- Using metrics like defect density, reliability, and performance to evaluate quality.
- Training and Awareness
- Educating team members about quality standards, tools, and techniques.
Promotes a culture of quality across the organization.
Formal Technical Review (FTR)
A Formal Technical Review (FTR) is a structured and planned meeting conducted by software professionals to evaluate software products (like design, code, or documentation) for errors, standards, and improvements before testing or release.
Guidelines for Formal Technical Review
1. The Objectives of an FTR Are:
- To uncover errors in function, logic, or implementation.
- To verify the software against requirements and standards.
- To ensure that the development process is followed correctly.
- To train team members by sharing knowledge and experiences.
- To promote consistency and quality in all deliverables.
2. The Review Meeting:
- Conducted in a formal, structured manner.
- Usually involves 3–5 participants: author, moderator, recorder, and reviewers.
- The agenda and materials are circulated in advance.
- Focus should be on finding errors, not criticizing individuals.
- The meeting should be time-limited (usually 1–2 hours).
3. Review Reporting and Record Keeping
- After the meeting, a formal report is prepared.
- The report includes: List of defects found, Decisions made during the review, Action items for correction.
- This record helps in tracking defect trends and process improvement.
Software Reliability Concepts
Software reliability is the probability that a software system will operate without failure under given conditions for a specified period of time.
Key Points on Reliability
- It measures the quality and stability of software.
- A highly reliable system functions correctly in all expected situations.
- It is one of the most important attributes of software quality.
- Reliability depends on error-free design, coding, and testing.
Factors Affecting Software Reliability
- Complexity: More complex systems are harder to make reliable.
- Testing Quality: Better testing increases reliability.
- Development Process: Following standards reduces defects.
- Hardware and Environment: Failures in hardware or OS can affect software reliability.
Measurement of Reliability
Mean Time Between Failures (MTBF) = MTTF + MTTR
- MTTF = Mean time to failure
- MTTR = Mean time to repair
- Availability = [MTTF/( MTTF + MTTR)]*100%
Software Safety
Definition:
Software Safety is the process of identifying, analyzing, and eliminating software failures that could lead to hazardous conditions or system failures. In simple words, it ensures that the software does not cause harm to people, equipment, or the environment even if it fails. It is a part of software reliability and quality assurance.
- Focuses on preventing accidents or damage due to software errors.
- Important in critical systems like aerospace, medical, defense, automotive, and nuclear industries.
Objectives of Software Safety
To detect and control safety-critical defects early in development.
- To minimize risks caused by software malfunction.
- To ensure safe system behavior, even in case of unexpected input or failure.
- To comply with safety standards such as ISO 26262 (automotive) or DO-178C (aviation).
Advantages of ISO 9000 Standards
Definition:
ISO 9000 is a set of international quality management standards that help organizations ensure their products and services meet customer and regulatory requirements. It provides a framework for quality assurance and continuous improvement.
Advantages
Improved Product Quality: Ensures products and services meet consistent quality standards. Reduces defects and rework.
- Customer Satisfaction: Focuses on meeting customer requirements and expectations.
- Builds trust and long-term relationships with clients.
- International Recognition: ISO 9000 is globally accepted, helping companies compete internationally.
- Useful for export and global partnerships.
- Better Process Control: Promotes standardized and documented procedures.
- Reduces variability in development and testing processes.
Software Quality Assurance (SQA) Plan
Definition:
A Software Quality Assurance (SQA) Plan is a documented plan that describes the procedures, techniques, and tools used to ensure that the software developed meets the required quality standards.
It defines how quality will be maintained, monitored, and measured throughout the software development life cycle (SDLC).
Objectives of SQA Plan
- To ensure the software meets customer and organizational quality requirements.
- To detect and prevent defects early in the development process.
- To define roles and responsibilities for all quality-related activities.
- To ensure that standards, methods, and procedures are followed properly.
Types of Quality Costs
Definition:
Quality cost refers to the total cost incurred in achieving and maintaining the desired quality level of a software product. It includes both the cost of ensuring quality and the cost of not meeting quality standards.
Types of Quality Costs
- Prevention Costs
- Appraisal Costs
- Internal Failure Costs
- External Failure Costs
Explanation of One Type – Prevention Cost
Definition:
Prevention cost is the cost incurred to prevent defects from occurring in the first place during software development.
Purpose:
To avoid failures and rework by ensuring that quality standards are followed from the beginning.
Examples:
- Training developers and testers.
- Preparing quality assurance plans.
- Conducting code reviews and inspections.
- Implementing process improvements.
Run-Time Measurement
Definition:
Run-Time refers to the period when a program is executing (i.e., after it has been loaded into memory and started by the operating system).
How to Create Run-Time Measurement
- Identify the segment of code or program you want to measure.
- Use timing functions or tools available in your programming language.
Example in Python:
import time
start = time.time()
# Code to execute
end = time.time()
print("Run-time:", end - start, "seconds")In Java: System.currentTimeMillis()
- Record start time just before execution begins.
- Record end time after execution ends.
- Calculate run-time: Run-Time = End Time − Start Time
How to Interpret Run-Time
- Lower run-time → Better performance
- Higher run-time → Inefficient code or heavy processing
- Compare run-times across different algorithms or different input sizes to evaluate efficiency.
