[Pkg-bazaar-commits] ./bzr/unstable r842: - don't say runit when running tests under python2.3 dammit

Martin Pool mbp at sourcefrog.net
Fri Apr 10 08:21:13 UTC 2009


------------------------------------------------------------
revno: 842
committer: Martin Pool <mbp at sourcefrog.net>
timestamp: Wed 2005-07-06 14:45:21 +1000
message:
  - don't say runit when running tests under python2.3 dammit
modified:
  testsweet.py
-------------- next part --------------
=== modified file 'testsweet.py'
--- a/testsweet.py	2005-07-06 04:40:52 +0000
+++ b/testsweet.py	2005-07-06 04:45:21 +0000
@@ -80,7 +80,7 @@
         super(TestBase, self).tearDown()
         self.log("%s teardown" % self.id())
         self.log('')
-        
+
 
     def formcmd(self, cmd):
         if isinstance(cmd, basestring):
@@ -233,7 +233,12 @@
 
     def startTest(self, test):
         # TODO: Maybe show test.shortDescription somewhere?
-        print >>self.out, '%-60.60s' % test.id(),
+        what = test.id()
+        # python2.3 has the bad habit of just "runit" for doctests
+        if what == 'runit':
+            what = test.shortDescription()
+        
+        print >>self.out, '%-60.60s' % what,
         self.out.flush()
         TestResult.startTest(self, test)
 



More information about the Pkg-bazaar-commits mailing list