Check return value of doctest.testmod()

Adapted from 41afa16500
This commit is contained in:
Ismael Juma 2015-07-21 09:53:17 +01:00
parent 061cdcef4a
commit 0c69a640f8
1 changed files with 3 additions and 1 deletions

View File

@ -440,6 +440,8 @@ def main():
if __name__ == "__main__":
import doctest
doctest.testmod()
(failure_count, test_count) = doctest.testmod()
if (failure_count):
exit(-1)
main()