def test_multi_reader2(self): a = StringIO.StringIO('你好') b = StringIO.StringIO('abcdefg') c = StringIO.StringIO(u'悲剧') mr = rpc.MultiReader([a, b, c]) data = mr.read(8) assert len(data) is 8
def test_multi_reader1(self): a = StringIO.StringIO('你好') b = StringIO.StringIO('abcdefg') c = StringIO.StringIO(u'悲剧') mr = rpc.MultiReader([a, b, c]) data = mr.read() assert data.index('悲剧') > data.index('abcdefg')