diff options
author | Rob Dennis <rdennis@gmail.com> | 2014-01-18 23:06:46 -0500 |
---|---|---|
committer | Rob Dennis <rdennis@gmail.com> | 2014-01-24 21:30:09 -0500 |
commit | 9a4455960195f71771c448027650b752cdd94718 (patch) | |
tree | ab0ccadb726f9add3abedbffcd05d34c7a2822bf /validate.py | |
parent | 65d7b557d7676c95482cb01bc8558af71538b0d5 (diff) | |
download | configobj-git-9a4455960195f71771c448027650b752cdd94718.tar.gz |
#3 - validate doctest errors correctly fail the build
Diffstat (limited to 'validate.py')
-rw-r--r-- | validate.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/validate.py b/validate.py index a39e103..003344e 100644 --- a/validate.py +++ b/validate.py @@ -1447,4 +1447,6 @@ if __name__ == '__main__': globs.update({ 'vtor': Validator(), }) - doctest.testmod(m, globs=globs) + + failures, tests = doctest.testmod(m, globs=globs) + assert not failures, '{} failures out of {} tests'.format(failures, tests) |