diff options
Diffstat (limited to 'nose/plugins/capture.py')
-rw-r--r-- | nose/plugins/capture.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/nose/plugins/capture.py b/nose/plugins/capture.py index fa4e5dc..5d26f26 100644 --- a/nose/plugins/capture.py +++ b/nose/plugins/capture.py @@ -95,6 +95,8 @@ class Capture(Plugin): def start(self): self.stdout.append(sys.stdout) self._buf = StringIO() + if not hasattr(self._buf, 'encoding'): + self._buf.encoding = sys.__stdout__.encoding sys.stdout = self._buf def end(self): |