It is possible to add some examples in the python documentation and run them to be sure they are working. Ref : https://docs.python.org/3/library/doctest.html