Spy-based testing library.
Clone or download
xkrogen [docs] Added a section to the tutorial about record-replay mocking. A…
…lso fixed some rst warnings in the tutorial and cleaned up whitespace in the file.
Latest commit 7ac262b Mar 17, 2016

README.rst

Bond - Testing with Spies and Mocks

Bond is a small library that can be used to spy values and mock functions during tests. Spying is a replacement for writing the assertEquals in your test, which are tedious to write and even more tedious to update when your test setup or code inevitably changes. With Bond, you separate what is being verified, e.g., the variable named output, from what value it should have. This way you can quickly spy several variables, even have structured values such as lists or dictionaries, and these values are saved into an observation log that is saved for future reference. If the test observations are different you have the option to interact with a console or visual tool to see what has changed, and whether the reference set of observations need to be updated.

For more examples please look at: