mercredi 6 mai 2015

What is the proper way to write unit tests in Python?

I have several .py files that I have written and that I import for various tasks. However with all the changes I make, sometimes something might break, so after some research apparently unit tests were designed to guard against this by having something to run to ensure that everything works.

Is there a standard format for this sort of thing or is it pretty much a giant script that runs every function in your library a few times against known results and tests to see which ones no longer match expected values?

Aucun commentaire:

Enregistrer un commentaire