Skip to content

Commit beeb029

Browse files
committed
CDRIVER-1530 test tailable mongoc_cursor_more
1 parent d117efb commit beeb029

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

tests/test-mongoc-cursor.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -904,6 +904,12 @@ test_tailable_alive (void)
904904

905905
/* still alive */
906906
ASSERT (mongoc_cursor_is_alive (cursor));
907+
ASSERT (mongoc_cursor_more (cursor));
908+
909+
/* no next document, but still alive and could return more in the future */
910+
ASSERT (!mongoc_cursor_next (cursor, &doc));
911+
ASSERT (mongoc_cursor_is_alive (cursor));
912+
ASSERT (mongoc_cursor_more (cursor));
907913

908914
mongoc_cursor_destroy (cursor);
909915
mongoc_collection_destroy (collection);

0 commit comments

Comments
 (0)