summaryrefslogtreecommitdiff
path: root/validate.py
diff options
context:
space:
mode:
authorRob Dennis <rdennis@gmail.com>2014-01-18 23:06:46 -0500
committerRob Dennis <rdennis@gmail.com>2014-01-24 21:30:09 -0500
commit9a4455960195f71771c448027650b752cdd94718 (patch)
treeab0ccadb726f9add3abedbffcd05d34c7a2822bf /validate.py
parent65d7b557d7676c95482cb01bc8558af71538b0d5 (diff)
downloadconfigobj-git-9a4455960195f71771c448027650b752cdd94718.tar.gz
#3 - validate doctest errors correctly fail the build
Diffstat (limited to 'validate.py')
-rw-r--r--validate.py4
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)