Testing can either break your code or make your code unbreakable. We recently talked about testing driven development, however in Object-Oriented paradigm testing need to take into account more thing than they noramally should.
- The case you want to test only applies to a particular class.
- There are testing methods that check wether or not the methods of the class are working correctly with each other.
- OO testing need to check if inheritance breaks the code because inheritance is an important part of the paradigm.
Those are a few different aproaches on testing on OO, I will mention a few below.
Code testing: this type of testing is carried out on the coding stage, you review the code, you debugg, etc.
Unit testing: This aproach review the system based on modules, each tester test modules to figure out what is the problem and how to solve it.
System testing: In this test, the tester will try the whole system at once, like a black box, to see what kind of input can break the program