|
| static void | fd_body (fr_dbuff_t *dbuff, uint8_t const data[]) |
| |
| static void | max_body (fr_dbuff_t *dbuff, uint8_t const data[]) |
| |
| static void | test_dbuff_advance_extend (void) |
| | Test fr_dbuff_advance_extend against a talloc-backed (extensible) dbuff.
|
| |
| static void | test_dbuff_child (void) |
| | Test the child-dbuff macros: FR_DBUFF, FR_DBUFF_ABS, FR_DBUFF_BIND_CURRENT, FR_DBUFF_BIND_CURRENT_ABS, FR_DBUFF_BIND_END_ABS and FR_DBUFF_MAX.
|
| |
| static void | test_dbuff_extend (void) |
| | Test the extension-request API: fr_dbuff_extend, fr_dbuff_extend_lowat, fr_dbuff_is_extendable and fr_dbuff_was_extended.
|
| |
| static void | test_dbuff_fd (void) |
| |
| static void | test_dbuff_fd_max (void) |
| |
| static void | test_dbuff_fd_shell (fr_dbuff_fd_test_body body, uint8_t const data[], size_t datasize, uint8_t buff[], size_t buffsize, size_t max) |
| |
| static void | test_dbuff_in_memcpy (void) |
| | Test fr_dbuff_in_memcpy, fr_dbuff_in_memcpy_partial and fr_dbuff_in_bytes_partial.
|
| |
| static void | test_dbuff_init (void) |
| |
| static void | test_dbuff_init_no_parent (void) |
| |
| static void | test_dbuff_marker_release (void) |
| | Test fr_dbuff_marker_release, fr_dbuff_marker_release_behind and _ahead.
|
| |
| static void | test_dbuff_max (void) |
| |
| static void | test_dbuff_measure (void) |
| | Test the measurement / accessor macros against both a dbuff and a marker.
|
| |
| static void | test_dbuff_memset (void) |
| | Test fr_dbuff_memset.
|
| |
| static void | test_dbuff_move (void) |
| |
| static void | test_dbuff_net_encode (void) |
| | Test the various dbuff_net_encode() functions and macros.
|
| |
| static void | test_dbuff_no_advance (void) |
| |
| static void | test_dbuff_out (void) |
| | Test functions that read from dbuffs.
|
| |
| static void | test_dbuff_out_int64v (void) |
| | Test fr_dbuff_out_int64v, which sign-extends based on the most significant bit.
|
| |
| static void | test_dbuff_set (void) |
| | Test fr_dbuff_set (by size_t, pointer, marker) and fr_dbuff_set_end.
|
| |
| static void | test_dbuff_shift (void) |
| | Test fr_dbuff_shift moves unconsumed content to the front of the buffer.
|
| |
| static void | test_dbuff_talloc_extend (void) |
| | Test extensible dbuffs.
|
| |
| static void | test_dbuff_talloc_extend_multi_level (void) |
| |
| static void | test_dbuff_tmp (void) |
| | Test FR_DBUFF_TMP, the compound-literal dbuff.
|
| |
| static void | test_dbuff_trim_reset_talloc (void) |
| | Test fr_dbuff_trim_talloc, fr_dbuff_reset_talloc and fr_dbuff_free_talloc.
|
| |
| static void | test_dbuff_update (void) |
| | Test fr_dbuff_update repoints the dbuff and its markers after a buffer move.
|
| |
| static void test_dbuff_child |
( |
void |
| ) |
|
|
static |
Test the child-dbuff macros: FR_DBUFF, FR_DBUFF_ABS, FR_DBUFF_BIND_CURRENT, FR_DBUFF_BIND_CURRENT_ABS, FR_DBUFF_BIND_END_ABS and FR_DBUFF_MAX.
These differ only in where the child's 'start' pointer is set (parent 'current' vs parent 'start') and whether writing to the child advances the parent's 'current' pointer, 'end' pointer, or neither.
Definition at line 515 of file dbuff_tests.c.
| static void test_dbuff_measure |
( |
void |
| ) |
|
|
static |
Test the measurement / accessor macros against both a dbuff and a marker.
Covers fr_dbuff_len, fr_dbuff_buff, fr_dbuff_end, fr_dbuff_ptr, fr_dbuff_behind and fr_dbuff_ahead, which the existing tests never touch.
Definition at line 586 of file dbuff_tests.c.
| static void test_dbuff_set |
( |
void |
| ) |
|
|
static |
Test fr_dbuff_set (by size_t, pointer, marker) and fr_dbuff_set_end.
The backing array is deliberately larger than the dbuff window so that we can form a pointer past the dbuff 'end' without forming a pointer outside the real allocation (which would be undefined behaviour).
Definition at line 628 of file dbuff_tests.c.