Fix split buffer with inconsistently delimited json objects.

Signed-off-by: Daniel Nephin <dnephin@docker.com>
This commit is contained in:
Daniel Nephin 2015-10-05 12:56:10 -04:00
commit 15d0c60a73
6 changed files with 62 additions and 22 deletions

View file

@ -47,7 +47,7 @@ class SplitBufferTest(unittest.TestCase):
self.assert_produces(reader, [string])
def assert_produces(self, reader, expectations):
split = split_buffer(reader(), u'\n')
split = split_buffer(reader())
for (actual, expected) in zip(split, expectations):
self.assertEqual(type(actual), type(expected))