SWE 437 In Class Exercise # 5
Faults and Failures (Note: Topic is K-Ch1)


Names:

Instructions: Work with your neighbors in groups.

Warm up: Identifying happy paths: Consider the following APIs. Take a few minutes to converger in your group on wwhat the happy paths are. Specifically, create a concrete test case that exercises the happy path. Create another concrete test case that does not. Once most folks seem on board, we'll move on. If you're not on board, please see me.

Now, on to the main event. Consider the cal() method from the homework.

You may also find these fun facts about the program to be of interest.

  1. What does it mean to test a program with a value that does not satisfy a precondition? For example, what about testing cal with month1 set to zero?



  2. For the variation that switches June and July, find a test that finds the fault. Find another test that does not.



  3. For the variation that uses the OR instead of the AND logic operator, find a test that finds the fault. Find another test that does not.



  4. For the boundary change that replaces LEQ (Less than or EQual) with NEQ (Not EQual), find a test that finds the fault. Find another test that does not.