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 ...
unittest (standard library)
https://pypi.python.org/pypi/coverage
But don't try to blindly increase coverage, read this first: How to Misuse Code Coverage