#!/usr/bin/env python # coding: utf-8 # # Testing Python Programs # # [back to main page](../index.ipynb) # # Due to the dynamic character of the Python language, many potential programming # errors are only detected at runtime. # To find some of them at an earlier stage, you should use *unit tests*, # *syntax checkers* and probably more ... # # https://wiki.python.org/moin/PythonTestingToolsTaxonomy # ## Built-In Unit Testing # # [unittest](https://docs.python.org/3.4/library/unittest.html) (standard library) # ## Testing Frameworks # # [nose](https://nose.readthedocs.org/en/latest/) # # [py.test](http://pytest.org/latest/) # # [tox](http://testrun.org/tox/latest/) # ## Code Coverage # # https://pypi.python.org/pypi/coverage # # But don't try to blindly increase coverage, read this first: # [How to Misuse Code Coverage](http://www.exampler.com/testing-com/writings/coverage.pdf) # ## Static Code Analysis # # [Syntax Checkers](syntax-checkers.ipynb) # ## External Links # # https://github.com/rasbt/python_reference/blob/master/tutorials/unit_testing.md # # https://blog.daftcode.pl/the-cleaning-hand-of-pytest-28f434f4b684 #

# # CC0 # #
# To the extent possible under law, # the person who associated CC0 # with this work has waived all copyright and related or neighboring # rights to this work. #