40 likes | 134 Views
Testing Programs with Branches. CSIS 1595: Fundamentals of Programming and P roblem Solving 1. Example Program. Test Cases. Need at least one test case for each possible outcome Each possible branch of each condition Example: At least one A 95 At least one B 85
E N D
Testing Programs with Branches CSIS 1595: Fundamentals of Programming and Problem Solving 1
Test Cases • Need at least one test case for each possible outcome • Each possible branch of each condition • Example: • At least one A 95 • At least one B 85 • At least one C 75
Boundary Testing • Need test cases at boundaries between possible outcomes • Good for catching errors in choice of relational operators • Example: • Boundary between Aand B 90 • Boundary between Band C 80