Description

>>> s_full = cbson.dumps({'a': 1}) + cbson.dumps({'b': 2.0}) >>> s = s_full[:-1] >>> cbson.decode_next(s) (12, {'a': 1}) >>> cbson.decode_next(s, 12) Traceback (most recent call last): ... BSONBufferTooShort: ('buffer too short: buffer[12:] does not contain 12 bytes for document', 1)

>>> s = s_full[:-2] >>> cbson.decode_next(s) (12, {'a': 1}) >>> cbson.decode_next(s, 12) Traceback (most recent call last): ... BSONBufferTooShort: ('buffer too short: buffer[12:] does not contain 12 bytes for document', 2)

test_decode_next_eob is referenced in 0 repositories