From 49a80f734c5a4ec8cbc359c6fc8099ddfbdfc6ba Mon Sep 17 00:00:00 2001 From: Daniel Wakefield Date: Thu, 4 Dec 2014 16:59:11 +0000 Subject: Change tests to use new CaptureOutput class. Added the ability to clear the buffers in the CaptureOutput class so it can be easily used multiple times in the same context manager. Also added a option to suppress the SystemExit associated with printing an error. Change-Id: Ib59bbbe88256f215eed0a8ebc8282e02181d4377 --- swiftclient/multithreading.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'swiftclient/multithreading.py') diff --git a/swiftclient/multithreading.py b/swiftclient/multithreading.py index a2dcd71..ade0f7b 100644 --- a/swiftclient/multithreading.py +++ b/swiftclient/multithreading.py @@ -86,6 +86,9 @@ class OutputManager(object): msg = msg % fmt_args self.error_print_pool.submit(self._print_error, msg) + def get_error_count(self): + return self.error_count + def _print(self, item, stream=None): if stream is None: stream = self.print_stream -- cgit v1.2.1