SLIDE 1
CSZone.co.uk
Click to advance · Arrow keys also work
Edexcel 1CP2 · Topic 1 · 1.2g

Testing
Strategies

Normal · Boundary · Erroneous · Error Types · Test Plans

CSZoneEdexcel GCSE Computer Science 1CP2
Types of Test Data

Three Categories You Must Know

TypeDescriptionExample (score 0–100)
NormalValid data that should be accepted50, 75, 30
BoundaryValues at the edge of valid range0, 1, 99, 100
ErroneousInvalid data that should be rejected-1, 101, "five"
Exam tip:Edexcel commonly asks you to give examples of all three types for a specific scenario.
Types of Errors

What Can Go Wrong in Code

Syntax error — code violates language rules. Detected before running. e.g. missing colon, misspelled keyword, unclosed bracket.
Logic error — code runs but produces wrong output. No error message. e.g. using + instead of *, wrong loop condition.
Runtime error — crash during execution. e.g. dividing by zero, accessing a list index that doesn't exist.
Testing Approaches

How to Test Effectively

Iterative testing — test each module as it is built; fix bugs before moving on
Final/terminal testing — test the complete system at the end of development
Test plans — document: test number, test data, expected output, actual output, pass/fail
Debugging tools: breakpoints (pause at a line), stepping through (line by line), print statements
Exam Practice

Have a go at this question

Edexcel-style question
A program accepts a temperature input between -50 and 50. Give one example each of: normal, boundary, and erroneous test data.
3 marks
Normal: 20 (valid temperature in range) [1]
Boundary: -50 or 50 (exact edge of valid range) [1]
Erroneous: -51, 51, or "hot" (invalid — outside range or wrong type) [1]
Key Takeaways

What to Remember

Normal (valid), Boundary (edge), Erroneous (invalid) — know all three
Errors: Syntax (grammar) · Logic (wrong result) · Runtime (crash)
Logic errors are hardest to find — no error message is generated
Iterative testing catches bugs early; terminal testing checks the complete system