Test Design in Practice
You've learned four test design techniques. Now let's apply them all to one scenario and see how they complement each other.
The Scenario
You're testing a movie ticket booking system with these rules:
Ticket pricing:
- Children (0-12): $8
- Adults (13-64): $15
- Seniors (65+): $10
Showtimes:
- Matinee (before 5pm): 20% discount on all tickets
- Evening (5pm and after): Regular price
Booking states:
- Available → Selected → Reserved (10-min hold) → Purchased
- Reserved seats return to Available after 10 minutes if not purchased
Your Assignment
Apply each technique to this scenario:
1. Equivalence Partitioning
Identify the equivalence classes for the age input. What are the valid and invalid partitions?
2. Boundary Value Analysis
List the boundary values for age and showtime. What values would you test at each boundary?
3. Decision Table
Build a decision table for ticket pricing. Conditions: age group (child/adult/senior) and showtime (matinee/evening). What are all the price combinations?
4. State Transition Testing
Draw the booking state transitions. What test cases cover the happy path? What invalid transitions should you test? (Hint: what happens if someone tries to purchase a seat that just timed out?)
Bonus Challenge
Combine all your test cases into a single test plan. How many tests do you need in total? Can any be combined without losing coverage?
The key takeaway: No single technique catches everything. Use them together — partition your inputs, test the boundaries, table the combinations, and trace the states.
For the movie ticket system, a matinee child ticket costs $8 with a 20% discount. What is the correct price?
The child ticket base price is $8. The matinee discount is 20%, so $8 × 0.80 = $6.40. This is exactly the type of combination that a decision table helps you identify and test.
Put these test design steps in the correct order for the movie ticket scenario.
A seat is in the "Reserved" state with a 10-minute hold. Which test case is MOST important for state transition testing?
The happy path (purchase within time), the timeout boundary (exactly 10 minutes), and the recovery path (another user buying after expiry) all test critical transitions around the reservation state. Missing any one could leave a significant bug untested.