Defect Impact: Defects can lead to harm to individuals or organizations.
Example: Defective road traffic control systems can lead to accidents, even causing deaths.
Monetary Impact: Defects can cause financial losses.
Example: If e-commerce sites like eBay or Amazon go down, they face massive revenue losses.
Quality Improvement: Testing identifies defects, which when fixed, improve software quality.
Risk Reduction: Proper testing of software reduces risks by identifying and fixing defects early.
Human Error: Humans make mistakes during development, and testing helps catch these mistakes.
Minor errors may not affect much, but critical applications like hospital or air traffic control systems must be tested thoroughly.
Software Systems Context
Personal Blogs: Errors don’t impact others significantly.
Business Websites: Errors can make the company appear unprofessional.
Banking Applications: Errors affect bank credibility; these systems must be reliable.
Air Traffic Control Systems: Must be thoroughly tested to ensure safety.
Causes of Software Defects
Requirement Phase: Mistakes in gathering requirements.
Design Phase: Flaws introduced during design.
Coding Phase: Errors during development.
Mistakes at any phase in the Software Development Life Cycle (SDLC) can introduce defects, known as bugs.
When Do Defects Arise?
Defects can arise in any phase: requirements, design, or development.
Different scenarios:
Requirement Correct: Design and development are correct, leading to correct software.
Development Error: Correct requirements and design, but errors in coding lead to defects.
Design Error: Correct requirements, but flawed design leads to defects, which are hard to fix.
Requirement Error: Incorrect requirements lead to fundamentally flawed software that meets design but not actual needs. These defects are identified in the User Acceptance Test (UAT) phase.
Cost of Defects
Early Detection: Less costly if defects are found in the requirements phase.
Late Detection: Cost increases exponentially if defects are detected in later stages like coding or production.
Graph: Shows cost increasing from requirements, through design, coding, testing, to production.
Role of Testing
Development and Maintenance: Identifies defects and ensures a higher quality product.
Operational Risk: Testing replicates operational environments to reduce the risk of failures.
Contractual and Legal: Some software must meet legal standards (e.g., air traffic control).