tests: fix CaptureStreamHandler on 2.6.
This commit is contained in:
parent
3429e57825
commit
592d6fc8d3
|
@ -160,12 +160,12 @@ def sync_with_broker(broker, timeout=10.0):
|
|||
|
||||
class CaptureStreamHandler(logging.StreamHandler):
|
||||
def __init__(self, *args, **kwargs):
|
||||
super(CaptureStreamHandler, self).__init__(*args, **kwargs)
|
||||
logging.StreamHandler.__init__(self, *args, **kwargs)
|
||||
self.msgs = []
|
||||
|
||||
def emit(self, msg):
|
||||
self.msgs.append(msg)
|
||||
return super(CaptureStreamHandler, self).emit(msg)
|
||||
logging.StreamHandler.emit(self, msg)
|
||||
|
||||
|
||||
class LogCapturer(object):
|
||||
|
|
Loading…
Reference in New Issue