diff --git a/tests/unittests/tests-chunked_ringbuffer/tests-chunked_ringbuffer.c b/tests/unittests/tests-chunked_ringbuffer/tests-chunked_ringbuffer.c index d2020ebf322a..5d69ea98a2fb 100644 --- a/tests/unittests/tests-chunked_ringbuffer/tests-chunked_ringbuffer.c +++ b/tests/unittests/tests-chunked_ringbuffer/tests-chunked_ringbuffer.c @@ -25,6 +25,12 @@ static void test_crb_add_and_consume(void) crb_init(&cb, buffer, sizeof(buffer)); + /* add a chunk but don't finish it */ + crb_start_chunk(&cb); + crb_add_byte(&cb, 1); + crb_add_byte(&cb, 2); + crb_add_byte(&cb, 3); + TEST_ASSERT(crb_add_chunk(&cb, "one", 4)); TEST_ASSERT(crb_add_chunk(&cb, "two", 4)); TEST_ASSERT(crb_add_chunk(&cb, "three", 6));