changeset 21993:284a8c9f74f3

run-tests: add iolock to failure output
author Matt Mackall <mpm@selenic.com>
date Mon, 04 Aug 2014 14:42:24 -0500
parents 6be1e1dbe6a0
children c6e1f2c6d5f1
files tests/run-tests.py
diffstat 1 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/tests/run-tests.py	Mon Aug 04 14:32:34 2014 -0500
+++ b/tests/run-tests.py	Mon Aug 04 14:42:24 2014 -0500
@@ -1085,10 +1085,12 @@
         if self._options.first:
             self.stop()
         else:
+            iolock.acquire()
             if not self._options.nodiff:
                 self.stream.write('\nERROR: %s output changed\n' % test)
 
             self.stream.write('!')
+            iolock.release()
 
     def addError(self, *args, **kwargs):
         super(TestResult, self).addError(*args, **kwargs)