Testing
Final testing, also called terminal testing, happens at the end of production, once every part of the program has been written. The whole program is run and tested together rather than one module at a time.
Imagine a ten-pin bowling program built from three modules: one records each player's score, one works out the team average, and one displays the leaderboard. The score module passed its own test because it displayed each score correctly, but it stored the score as text. In final testing you play a whole game through the program and spot that the average module joins "12" and "18" into "1218" instead of adding them. The fault only appears when the modules are joined.
| Iterative testing | Final testing |
|---|---|
| Carried out during development | Carried out at the end of production |
| Tests one module at a time | Tests the finished program as a whole |
| Finds errors early, while the module is being written | Finds errors caused by modules working together |
Both are needed. A module can pass every test on its own and still fail when it is joined to another module, because the two may expect different data or the wrong value may be passed between them. Final testing is the only stage that runs the complete program from start to finish, so it is the only stage that can show the program works as one piece.
OCR GCSE Computer Science · Testing