def test_load_header(): stream = io.StringIO() a = TextStream(stream) a.write_header("hoge") stream.seek(0) assert a.load_header() == "hoge"
def test_write_header(): stream = io.StringIO() a = TextStream(stream) a.write_header("hoge") stream.seek(0) assert stream.readline() == "hoge\n"