diff --git a/src/useful_scripts/doctest_example.py b/src/useful_scripts/doctest_example.py new file mode 100644 index 0000000..104fc14 --- /dev/null +++ b/src/useful_scripts/doctest_example.py @@ -0,0 +1,11 @@ +''' +The doctest module automatically runs any statement begining with >>> +and compares the following line with the output from the interpreter. + +>>> 1 == 1 +False +''' + +if __name__ == '__main__': + import doctest + doctest.testmod() \ No newline at end of file