Structured Programming Tests
“Testing shows the presence, not the absence, of bugs.” - Dijkstra
A program can be proven incorrect by a test, but it cannot be proven correct. All that tests can do, after sufficient testing effort, is allow us to deem a program to be correct enough for our purposes.
Software is like a science. We show correctness by failing to prove incorrectness, despite our best efforts.
Structured programming forces us to recursively decompose a program into a set of small provable functions.
We can then use tests to try to prove those small provable functions incorrect. If such tests fail to prove incorrectness, then we deem the functions to be correct enough for our purposes.
Software architects strive to define modules, components, and services that are easily falsifiable (testable). To do so, they employ restrictive disciplines similar to structured programming, albeit at a much higher level.