]> git.parisson.com Git - timeside.git/commitdiff
Test : Add a message when a test is skipped
authorThomas Fillon <thomas@parisson.com>
Fri, 22 Nov 2013 13:52:46 +0000 (14:52 +0100)
committerThomas Fillon <thomas@parisson.com>
Fri, 22 Nov 2013 13:52:46 +0000 (14:52 +0100)
tests/unit_timeside.py

index 96d0e56b514d46a80d8ab5f963497d0091250400..46bc35354ad45fce9b736533340f6ef7947d141d 100644 (file)
@@ -74,6 +74,13 @@ class _TextTestResult(unittest.TestResult):
         elif self.dots:
             self.stream.write('F')
 
+    def addSkip(self, test, reason):
+        unittest.TestResult.addSkip(self, test, reason)
+        if self.showAll:
+            self.stream.writeln("SKIP : " + reason)
+        elif self.dots:
+            self.stream.write('S')
+
     def printErrors(self):
         if self.dots or self.showAll:
             self.stream.writeln()