More defects => more chances of failure => lesser reliability
Faults & Failure
- Failure: A software failure occurs if the behavior of the s/w is different from expected/specified.
- Fault: cause of software failure
- Fault = bug = defect
- Failure implies presence of defects
Role of Testing
- Reviews are human processes – can not catch all defects
- Hence there will be requirement defects, design defects and coding defects in code
- These defects have to be identified by testing
- Therefore testing plays a critical role in ensuring quality.
- All defects remaining from before as well as new ones introduced have to be identified by testing.
Detecting defects in Testing
- During testing, an application is executed with a set of test cases
- Failure during testing => defects are present
- No failure => confidence grows, but can not say “defects are absent”
- Defects detected through failures
- To detect defects, must cause failures during testing
- Application often fail on special cases
- These depend on nature of inputs, types of data structures,etc.
- No good rules to identify them
- One way is to guess when the software might fail and create those test cases
- Also called error guessing.
make it perfect!