Software Testing
Content Essence Terminology Classification –Unit, System … –BlackBox, WhiteBox Debugging IEEE Standards
Definition Glen Myers –Testing is the process of executing a program with the intent of finding errors
Objective explained Paul Jorgensen –Testing is obviously concerned with errors, faults, failures and incidents. A test is the act of exercising software with test cases with an objective of Finding failure Demonstrate correct execution
A Testing Life Cycle Requirement Specs Design Coding Testing Fault Resolution Fault Isolation Fault Classification Error Fault Error incident Fix
Terminology Error –Represents mistakes made by people Fault –Is result of error. May be categorized as Fault of Commission – we enter something into representation that is incorrect Fault of Omission – Designer can make error of omission, the resulting fault is that something is missing that should have been present in the representation
Cont… Failure –Occurs when fault executes. Incident –Behavior of fault. An incident is the symptom(s) associated with a failure that alerts user to the occurrence of a failure Test case –Associated with program behavior. It carries set of input and list of expected output
Cont… Verification –Process of determining whether output of one phase of development conforms to its previous phase. Validation –Process of determining whether a fully developed system conforms to its SRS document
Verification versus Validation Verification is concerned with phase containment of errors Validation is concerned about the final product to be error free
Relationship – program behaviors Program Behaviors Specified (expected) Behavior Programmed (observed) Behavior Fault Of Omission Fault Of Commission Correct portion
Classification of Test There are two levels of classification –One distinguishes at granularity level Unit level System level Integration level –Other classification (mostly for unit level) is based on methodologies Black box (Functional) Testing White box (Structural) Testing
Relationship – Testing wrt Behavior Program Behaviors Specified (expected) Behavior Programmed (observed) Behavior Test Cases (Verified behavior)
Cont… 2, 5 –Specified behavior that are not tested 1, 4 –Specified behavior that are tested 3, 7 –Test cases corresponding to unspecified behavior
Cont… 2, 6 –Programmed behavior that are not tested 1, 3 –Programmed behavior that are tested 4, 7 –Test cases corresponding to un- programmed behaviors
Inferences If there are specified behaviors for which there are no test cases, the testing is incomplete If there are test cases that correspond to unspecified behaviors –Either such test cases are unwarranted –Specification is deficient (also implies that testers should participate in specification and design reviews) er way of computing cyclomatic complexity: –determine number of bounded areas in the graph Any region enclosed by a nodes and edge sequence. V(G) = Total number of bounded areas + 1