One of the programming techniques I really learned to love at Google is unit-testing. One important aspect of unit-testing is writing mocks, so that a given implementation can be tested against those mocks. Mocks are basically extremely simple implementation of a given interface, but that can verify certain assumptions. You can verify that the interface is called with correct parameters, and you can also have your mocks fail, so that you can test your error handling code. The C++ mocking framework I’m using at work has now been open-sourced under the BSD license. The framework works under Linux, Mac OS X and Windows.
Interesting. Do you have a link to a simple example?
There is a dummy example of the cheat-sheet: http://code.google.com/p/googlemock/wiki/CheatSheet