301.13 Testing
Practise exam questionsTesting — Note 4 of 6
Compare predicted output.
Before running a test, predict the expected output. Then run the program and compare with the actual output. If they differ, there is a bug to investigate.
# Test: input 15 into age checker (pass mark >=18)
# Expected output: "Minor"
# Actual output: "Minor" ✓ PASS
# Test: input 18
# Expected: "Adult"
# Actual: "Minor" ✗ FAIL — bug in conditionSpecification notes for programming are in Paper 2.