#include <freeradius-devel/util/acutest.h>
#include <freeradius-devel/util/acutest_helpers.h>
#include <freeradius-devel/util/dict_test.h>
#include <freeradius-devel/server/tmpl_dcursor.h>
#include <freeradius-devel/server/pair.h>
Go to the source code of this file.
◆ tmpl_dcursor_vars_t
struct tmpl_dcursor_vars_t |
◆ build_test_end
Value:
TEST_CHECK_PAIR(
test_vp(), NULL); \
tmpl_dcursor_clear(&vars.cc)
static void * fr_dcursor_next(fr_dcursor_t *cursor)
Advanced the cursor to the next item.
static void debug_attr_list(fr_pair_list_t *list, int indent)
Definition at line 197 of file tmpl_dcursor_tests.c.
◆ common_vars
◆ pair_defs
Value:
fr_pair_t *string_vp ## _x; \
fr_pair_t *group_vp ## _x; \
fr_pair_t *child_vp ## _x; \
fr_pair_t *top_vp ## _x; \
fr_pair_t *mid_vp ## _x; \
fr_pair_t *leaf_string_vp ## _x; \
fr_pair_t *leaf_int32_vp ## _x
Stores an attribute, a value and various bits of other data.
Definition at line 55 of file tmpl_dcursor_tests.c.
◆ pair_defs_thin
Value:
fr_pair_t *group_vp ## _x; \
fr_pair_t *top_vp ## _x; \
fr_pair_t *mid_vp ## _x; \
fr_pair_t *leaf_int32_vp ## _x
Definition at line 65 of file tmpl_dcursor_tests.c.
◆ pair_populate
Value: do { \
} while (0)
fr_dict_attr_t const * fr_dict_attr_test_nested_leaf_string
fr_dict_attr_t const * fr_dict_attr_test_int32
fr_dict_attr_t const * fr_dict_attr_test_int16
fr_dict_attr_t const * fr_dict_attr_test_nested_top_tlv
fr_dict_attr_t const * fr_dict_attr_test_string
fr_dict_attr_t const * fr_dict_attr_test_nested_child_tlv
fr_dict_attr_t const * fr_dict_attr_test_group
fr_dict_attr_t const * fr_dict_attr_test_nested_leaf_int32
Definition at line 72 of file tmpl_dcursor_tests.c.
◆ pair_populate_thin
#define pair_populate_thin |
( |
|
_x | ) |
|
◆ test_cursor
#define test_cursor |
( |
| ) |
&vars.cursor |
◆ test_end
Value:
TEST_CHECK_PAIR(vars.vp, NULL); \
TEST_MSG("Cursor should've been empty (i.e. returned NULL) at end of test"); \
tmpl_dcursor_clear(&vars.cc); \
Definition at line 184 of file tmpl_dcursor_tests.c.
◆ TEST_INIT
◆ test_vp
◆ test_vp_p
◆ test_vp_set
◆ tmpl_setup_and_cursor_build_init
◆ tmpl_setup_and_cursor_init
◆ _tmpl_setup_and_cursor_build_init()
Initialise a tmpl using the _attr_str string, and return the first pair.
- Parameters
-
[out] | vp_out | where to write the returned pair. |
[in,out] | vars | test variables |
[in] | request | the current request. |
[in] | ref | Attribute reference string. |
Definition at line 160 of file tmpl_dcursor_tests.c.
◆ _tmpl_setup_and_cursor_init()
Initialise a tmpl using the _attr_str string, and return the first pair.
- Parameters
-
[out] | vp_out | where to write the returned pair |
[in,out] | vars | test variables |
[in] | request | the current request. |
[in] | ref | Attribute reference string. |
Definition at line 131 of file tmpl_dcursor_tests.c.
◆ debug_attr_list()
◆ request_fake_alloc()
static request_t* request_fake_alloc |
( |
void |
| ) |
|
|
static |
◆ test_init()
static void test_init |
( |
void |
| ) |
|
|
static |
◆ test_level_1_build()
static void test_level_1_build |
( |
void |
| ) |
|
|
static |
◆ test_level_1_one()
static void test_level_1_one |
( |
void |
| ) |
|
|
static |
◆ test_level_1_one_all()
static void test_level_1_one_all |
( |
void |
| ) |
|
|
static |
◆ test_level_1_one_last()
static void test_level_1_one_last |
( |
void |
| ) |
|
|
static |
◆ test_level_1_one_missing()
static void test_level_1_one_missing |
( |
void |
| ) |
|
|
static |
◆ test_level_1_one_second()
static void test_level_1_one_second |
( |
void |
| ) |
|
|
static |
◆ test_level_1_two()
static void test_level_1_two |
( |
void |
| ) |
|
|
static |
◆ test_level_1_two_all()
static void test_level_1_two_all |
( |
void |
| ) |
|
|
static |
◆ test_level_1_two_count()
static void test_level_1_two_count |
( |
void |
| ) |
|
|
static |
◆ test_level_1_two_last()
static void test_level_1_two_last |
( |
void |
| ) |
|
|
static |
◆ test_level_1_two_second()
static void test_level_1_two_second |
( |
void |
| ) |
|
|
static |
◆ test_level_1_two_third()
static void test_level_1_two_third |
( |
void |
| ) |
|
|
static |
◆ test_level_2_build_intermediate()
static void test_level_2_build_intermediate |
( |
void |
| ) |
|
|
static |
◆ test_level_2_build_leaf()
static void test_level_2_build_leaf |
( |
void |
| ) |
|
|
static |
◆ test_level_2_build_multi()
static void test_level_2_build_multi |
( |
void |
| ) |
|
|
static |
◆ test_level_2_one()
static void test_level_2_one |
( |
void |
| ) |
|
|
static |
◆ test_level_2_one_all()
static void test_level_2_one_all |
( |
void |
| ) |
|
|
static |
◆ test_level_2_one_missing()
static void test_level_2_one_missing |
( |
void |
| ) |
|
|
static |
◆ test_level_2_one_second()
static void test_level_2_one_second |
( |
void |
| ) |
|
|
static |
◆ test_level_2_two()
static void test_level_2_two |
( |
void |
| ) |
|
|
static |
◆ test_level_2_two_all()
static void test_level_2_two_all |
( |
void |
| ) |
|
|
static |
◆ test_level_2_two_last()
static void test_level_2_two_last |
( |
void |
| ) |
|
|
static |
◆ test_level_2_two_missing()
static void test_level_2_two_missing |
( |
void |
| ) |
|
|
static |
◆ test_level_2_two_second()
static void test_level_2_two_second |
( |
void |
| ) |
|
|
static |
◆ test_level_3_build_entire()
static void test_level_3_build_entire |
( |
void |
| ) |
|
|
static |
◆ test_level_3_build_invalid1()
static void test_level_3_build_invalid1 |
( |
void |
| ) |
|
|
static |
◆ test_level_3_build_invalid2()
static void test_level_3_build_invalid2 |
( |
void |
| ) |
|
|
static |
◆ test_level_3_build_leaf()
static void test_level_3_build_leaf |
( |
void |
| ) |
|
|
static |
◆ test_level_3_build_partial()
static void test_level_3_build_partial |
( |
void |
| ) |
|
|
static |
◆ test_level_3_one()
static void test_level_3_one |
( |
void |
| ) |
|
|
static |
◆ test_level_3_one_all()
static void test_level_3_one_all |
( |
void |
| ) |
|
|
static |
◆ test_level_3_one_second()
static void test_level_3_one_second |
( |
void |
| ) |
|
|
static |
◆ test_level_3_two()
static void test_level_3_two |
( |
void |
| ) |
|
|
static |
◆ test_level_3_two_all()
static void test_level_3_two_all |
( |
void |
| ) |
|
|
static |
◆ test_level_3_two_last()
static void test_level_3_two_last |
( |
void |
| ) |
|
|
static |
◆ autofree
◆ test_dict
◆ TEST_LIST