summaryrefslogtreecommitdiff
path: root/python/subunit
diff options
context:
space:
mode:
authorJonathan Lange <jml@canonical.com>2010-10-19 09:56:26 +0100
committerJonathan Lange <jml@canonical.com>2010-10-19 09:56:26 +0100
commitb7391e8a2ec77a1d9637feff35e949f35efbd4fe (patch)
tree6012406247714c6d2b30f5edaa57cc934ea37158 /python/subunit
parent8147bac30a7540305c9410cee0df8b406393b416 (diff)
parentff0991fae730da6140dd3f7e8716125aae3b9891 (diff)
downloadsubunit-git-b7391e8a2ec77a1d9637feff35e949f35efbd4fe.tar.gz
Merge mgz's patch for flushing the TestProtocolClient stream.
Diffstat (limited to 'python/subunit')
-rw-r--r--python/subunit/__init__.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/python/subunit/__init__.py b/python/subunit/__init__.py
index b6f0108..b2c7a29 100644
--- a/python/subunit/__init__.py
+++ b/python/subunit/__init__.py
@@ -646,7 +646,13 @@ class TestProtocolClient(testresult.TestResult):
def startTest(self, test):
"""Mark a test as starting its test run."""
+ super(TestProtocolClient, self).startTest(test)
self._stream.write("test: %s\n" % test.id())
+ self._stream.flush()
+
+ def stopTest(self, test):
+ super(TestProtocolClient, self).stopTest(test)
+ self._stream.flush()
def progress(self, offset, whence):
"""Provide indication about the progress/length of the test run.