~ubuntu-branches/ubuntu/raring/python-docutils/raring-201211091312

« back to all changes in this revision

Viewing changes to debian/patches/alltest-exitcode.diff

  • Committer: Bazaar Package Importer
  • Author(s): Jakub Wilk
  • Date: 2010-07-24 09:03:32 UTC
  • mfrom: (11.1.1 experimental)
  • Revision ID: james.westby@ubuntu.com-20100724090332-n30aqcft3axs8xd3
* Upload to unstable.
* Replace patch to fix --local option for tools/buildhtml.py
  (17_revert_buildhtml.diff) with the one that was applied upstream
  (buildhtml-local.diff).

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
Description: Make test suite runner exit with code 0 if all test passes.
2
 
Origin: upstream, http://svn.berlios.de/viewcvs/docutils/trunk/docutils/test/alltests.py?r1=6116&r2=6296
3
 
Last-Update: 2010-03-31
4
 
 
5
 
--- a/test/alltests.py
6
 
+++ b/test/alltests.py
7
 
@@ -83,4 +83,8 @@
8
 
     #    print >>sys.stderr, pformat(suite) # check the test suite
9
 
     finish = time.time()
10
 
     print 'Elapsed time: %.3f seconds' % (finish - start)
11
 
-    sys.exit(result)
12
 
+    if result.errors or result.failures:
13
 
+        # return test result object to enable processing in programmatic use
14
 
+        sys.exit(result)
15
 
+    else: # no problems, exit with zero
16
 
+        sys.exit()