pyecharts/test/__init__.py
LeoSun 6098c897b2 support render chart at Zeppelin and nteract (#1215)
* support render chart at Zeppelin and nteract

* Format: code

* update test code

* update test_map_globe code

* update test_map_globe code again
2019-06-28 19:28:59 +08:00

21 lines
359 B
Python

import sys
class ConsoleOutputRedirect:
""" Wrapper to redirect stdout or stderr """
def __init__(self, fp):
self.fp = fp
def write(self, s):
self.fp.write(s)
def writelines(self, lines):
self.fp.writelines(lines)
def flush(self):
self.fp.flush()
stdout_redirect = ConsoleOutputRedirect(sys.stdout)