syslog-ng source
test_dot_notation.c File Reference
#include <criterion/criterion.h>
#include "libtest/msg_parse_lib.h"
#include "dot-notation.h"
#include "apphook.h"
#include <json.h>
Include dependency graph for test_dot_notation.c:

Functions

void setup (void)
 
void teardown (void)
 
 TestSuite (json,.init=setup,.fini=teardown)
 
 Test (json, test_dot_notation_eval_empty_subscript_returns_the_object)
 
 Test (json, test_dot_notation_eval_fails_with_an_identifier_that_doesnt_start_with_a_letter)
 
 Test (json, test_dot_notation_eval_fails_with_an_identifier_that_contains_a_non_alnum_character)
 
 Test (json, test_dot_notation_eval_fails_with_an_incorrect_array_reference)
 
 Test (json, test_dot_notation_eval_succeeds_with_an_identifier_that_contains_all_possible_character_classes)
 
 Test (json, test_dot_notation_eval_object_subscript_extracts_the_child_object)
 
 Test (json, test_dot_notation_eval_object_succeeds_with_odd_or_invalid_js_identifier)
 
 Test (json, test_dot_notation_eval_object_member_from_non_object_fails)
 
 Test (json, test_dot_notation_eval_array_item_from_non_array_fails)
 
 Test (json, test_dot_notation_eval_array_item_by_index)
 
 Test (json, test_dot_notation_eval_multi_array_item_by_multiple_indexes)
 
 Test (json, test_dot_notation_eval_fails_with_out_of_bounds_index)
 

Function Documentation

◆ setup()

void setup ( void  )

◆ teardown()

void teardown ( void  )

◆ Test() [1/12]

Test ( json  ,
test_dot_notation_eval_array_item_by_index   
)

◆ Test() [2/12]

Test ( json  ,
test_dot_notation_eval_array_item_from_non_array_fails   
)

◆ Test() [3/12]

Test ( json  ,
test_dot_notation_eval_empty_subscript_returns_the_object   
)

◆ Test() [4/12]

Test ( json  ,
test_dot_notation_eval_fails_with_an_identifier_that_contains_a_non_alnum_character   
)

◆ Test() [5/12]

Test ( json  ,
test_dot_notation_eval_fails_with_an_identifier_that_doesnt_start_with_a_letter   
)

◆ Test() [6/12]

Test ( json  ,
test_dot_notation_eval_fails_with_an_incorrect_array_reference   
)

◆ Test() [7/12]

Test ( json  ,
test_dot_notation_eval_fails_with_out_of_bounds_index   
)

◆ Test() [8/12]

Test ( json  ,
test_dot_notation_eval_multi_array_item_by_multiple_indexes   
)

◆ Test() [9/12]

Test ( json  ,
test_dot_notation_eval_object_member_from_non_object_fails   
)

◆ Test() [10/12]

Test ( json  ,
test_dot_notation_eval_object_subscript_extracts_the_child_object   
)

◆ Test() [11/12]

Test ( json  ,
test_dot_notation_eval_object_succeeds_with_odd_or_invalid_js_identifier   
)

◆ Test() [12/12]

Test ( json  ,
test_dot_notation_eval_succeeds_with_an_identifier_that_contains_all_possible_character_classes   
)

◆ TestSuite()

TestSuite ( json  ,
init = setup,
fini = teardown 
)