test_dlist.c
Test suite for the doubly-linked list (t_dlist) implementation.
Covers ft_dlstnew(), ft_dlstadd_back(), ft_dlstsize().
- Author
pulgamecanica (arosado-)
Forward and backward traversal via ->next / ->prev, and ft_dlstclear().
This suite is always compiled and always runs — it is not guarded by a feature flag because t_list is a core Libft primitive.
Functions
-
static void del_int(void *content)
-
void test_dlist_suite(void)
Run all doubly-linked list assertions.
Builds a three-node list
[1 <-> 2 <-> 3], verifies size, forward and backward links, sentinel NULL values at both ends, then calls ft_dlstclear() and asserts the head pointer is NULL afterwards.