From: Kevin Day Date: Wed, 4 Sep 2024 23:31:38 +0000 (-0500) Subject: Update: Recent changes to the FSS implementations did not account for the unit tests. X-Git-Url: https://git.kevux.org/?a=commitdiff_plain;h=d6323d138f846d0ba39c3e44b29418fd731ebf27;p=fll Update: Recent changes to the FSS implementations did not account for the unit tests. --- diff --git a/level_1/fl_fss/c/fss/embedded_list.h b/level_1/fl_fss/c/fss/embedded_list.h index deedba1..ba20d7b 100644 --- a/level_1/fl_fss/c/fss/embedded_list.h +++ b/level_1/fl_fss/c/fss/embedded_list.h @@ -48,7 +48,7 @@ extern "C" { #define fl_fss_data_embedded_list_t_initialize { 0, 0, 0 } - #define macro_fl_fss_data_embedded_list_t_initialize_1(objects, closes, positions, slashes) { objects, positions, slashes } + #define macro_fl_fss_data_embedded_list_t_initialize_1(objects, positions, slashes) { objects, positions, slashes } #define macro_fl_fss_data_embedded_list_t_clear(data) \ data.objects = 0; \ diff --git a/level_1/fl_fss/data/tests/objects/basic_list-all_read.txt b/level_1/fl_fss/data/tests/objects/basic_list-all_read.txt index 022a5a7..63394ab 100644 --- a/level_1/fl_fss/data/tests/objects/basic_list-all_read.txt +++ b/level_1/fl_fss/data/tests/objects/basic_list-all_read.txt @@ -2,7 +2,7 @@ first empty third fourth -spaces around +spaces around To "disable" Has\ Also Has\\ diff --git a/level_1/fl_fss/data/tests/objects/embedded_list-all_read.txt b/level_1/fl_fss/data/tests/objects/embedded_list-all_read.txt index 022a5a7..63394ab 100644 --- a/level_1/fl_fss/data/tests/objects/embedded_list-all_read.txt +++ b/level_1/fl_fss/data/tests/objects/embedded_list-all_read.txt @@ -2,7 +2,7 @@ first empty third fourth -spaces around +spaces around To "disable" Has\ Also Has\\ diff --git a/level_1/fl_fss/data/tests/objects/extended_list-all_read.txt b/level_1/fl_fss/data/tests/objects/extended_list-all_read.txt index 022a5a7..63394ab 100644 --- a/level_1/fl_fss/data/tests/objects/extended_list-all_read.txt +++ b/level_1/fl_fss/data/tests/objects/extended_list-all_read.txt @@ -2,7 +2,7 @@ first empty third fourth -spaces around +spaces around To "disable" Has\ Also Has\\ diff --git a/level_1/fl_fss/tests/unit/c/test-fss-extended_list_content_read.c b/level_1/fl_fss/tests/unit/c/test-fss-extended_list_content_read.c index 6c75e6e..b7129e9 100644 --- a/level_1/fl_fss/tests/unit/c/test-fss-extended_list_content_read.c +++ b/level_1/fl_fss/tests/unit/c/test-fss-extended_list_content_read.c @@ -7,6 +7,7 @@ extern "C" { void test__fl_fss_extended_list_content_read__parameter_checking(void **void_state) { f_state_t state = f_state_t_initialize; + f_range_t close = f_range_t_initialize; f_range_t range = f_range_t_initialize; f_ranges_t found = f_ranges_t_initialize; f_ranges_t comments = f_ranges_t_initialize; @@ -15,7 +16,7 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, 0, 0, 0, 0, &state); + fl_fss_extended_list_content_read(f_string_empty_s, 0, 0, 0, 0, 0, &state); assert_int_equal(state.status, F_status_set_error(F_parameter)); } @@ -23,7 +24,7 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, &range, 0, 0, 0, &state); + fl_fss_extended_list_content_read(f_string_empty_s, &range, 0, 0, 0, 0, &state); assert_int_equal(state.status, F_status_set_error(F_parameter)); } @@ -31,7 +32,7 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, &range, &found, 0, 0, &state); + fl_fss_extended_list_content_read(f_string_empty_s, &range, &found, 0, 0, 0, &state); assert_int_equal(state.status, F_status_set_error(F_parameter)); } @@ -39,7 +40,7 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, &range, &found, &delimits, 0, &state); + fl_fss_extended_list_content_read(f_string_empty_s, &range, &found, 0, &delimits, 0, &state); assert_int_equal(state.status, F_status_set_error(F_parameter)); } @@ -47,7 +48,7 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, &range, &found, 0, &comments, &state); + fl_fss_extended_list_content_read(f_string_empty_s, &range, &found, 0, 0, &comments, &state); assert_int_equal(state.status, F_status_set_error(F_parameter)); } @@ -55,7 +56,7 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, &range, 0, &delimits, 0, &state); + fl_fss_extended_list_content_read(f_string_empty_s, &range, 0, &close, 0, 0, &state); assert_int_equal(state.status, F_status_set_error(F_parameter)); } @@ -63,7 +64,7 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, &range, 0, &delimits, &comments, &state); + fl_fss_extended_list_content_read(f_string_empty_s, &range, 0, &close, &delimits, 0, &state); assert_int_equal(state.status, F_status_set_error(F_parameter)); } @@ -71,7 +72,7 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, &range, 0, 0, &comments, &state); + fl_fss_extended_list_content_read(f_string_empty_s, &range, 0, &close, &delimits, &comments, &state); assert_int_equal(state.status, F_status_set_error(F_parameter)); } @@ -79,7 +80,7 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, 0, &found, 0, 0, &state); + fl_fss_extended_list_content_read(f_string_empty_s, &range, 0, &close, 0, &comments, &state); assert_int_equal(state.status, F_status_set_error(F_parameter)); } @@ -87,7 +88,7 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, 0, &found, &delimits, 0, &state); + fl_fss_extended_list_content_read(f_string_empty_s, &range, 0, 0, &delimits, 0, &state); assert_int_equal(state.status, F_status_set_error(F_parameter)); } @@ -95,7 +96,7 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, 0, &found, 0, &comments, &state); + fl_fss_extended_list_content_read(f_string_empty_s, &range, 0, 0, &delimits, &comments, &state); assert_int_equal(state.status, F_status_set_error(F_parameter)); } @@ -103,7 +104,7 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, 0, &found, &delimits, &comments, &state); + fl_fss_extended_list_content_read(f_string_empty_s, &range, 0, 0, 0, &comments, &state); assert_int_equal(state.status, F_status_set_error(F_parameter)); } @@ -111,7 +112,7 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, 0, 0, &delimits, 0, &state); + fl_fss_extended_list_content_read(f_string_empty_s, 0, &found, 0, 0, 0, &state); assert_int_equal(state.status, F_status_set_error(F_parameter)); } @@ -119,7 +120,7 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, 0, 0, &delimits, &comments, &state); + fl_fss_extended_list_content_read(f_string_empty_s, 0, &found, &close, 0, 0, &state); assert_int_equal(state.status, F_status_set_error(F_parameter)); } @@ -127,7 +128,103 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, 0, 0, 0, &comments, &state); + fl_fss_extended_list_content_read(f_string_empty_s, 0, &found, 0, &delimits, 0, &state); + + assert_int_equal(state.status, F_status_set_error(F_parameter)); + } + + { + state.status = F_none; + + fl_fss_extended_list_content_read(f_string_empty_s, 0, &found, 0, 0, &comments, &state); + + assert_int_equal(state.status, F_status_set_error(F_parameter)); + } + + { + state.status = F_none; + + fl_fss_extended_list_content_read(f_string_empty_s, 0, &found, &close, &delimits, 0, &state); + + assert_int_equal(state.status, F_status_set_error(F_parameter)); + } + + { + state.status = F_none; + + fl_fss_extended_list_content_read(f_string_empty_s, 0, &found, &close, 0, &comments, &state); + + assert_int_equal(state.status, F_status_set_error(F_parameter)); + } + + { + state.status = F_none; + + fl_fss_extended_list_content_read(f_string_empty_s, 0, &found, &close, &delimits, &comments, &state); + + assert_int_equal(state.status, F_status_set_error(F_parameter)); + } + + { + state.status = F_none; + + fl_fss_extended_list_content_read(f_string_empty_s, 0, &found, 0, &delimits, &comments, &state); + + assert_int_equal(state.status, F_status_set_error(F_parameter)); + } + + { + state.status = F_none; + + fl_fss_extended_list_content_read(f_string_empty_s, 0, 0, &close, 0, 0, &state); + + assert_int_equal(state.status, F_status_set_error(F_parameter)); + } + + { + state.status = F_none; + + fl_fss_extended_list_content_read(f_string_empty_s, 0, 0, &close, &delimits, 0, &state); + + assert_int_equal(state.status, F_status_set_error(F_parameter)); + } + + { + state.status = F_none; + + fl_fss_extended_list_content_read(f_string_empty_s, 0, 0, &close, 0, &comments, &state); + + assert_int_equal(state.status, F_status_set_error(F_parameter)); + } + + { + state.status = F_none; + + fl_fss_extended_list_content_read(f_string_empty_s, 0, 0, &close, &delimits, &comments, &state); + + assert_int_equal(state.status, F_status_set_error(F_parameter)); + } + + { + state.status = F_none; + + fl_fss_extended_list_content_read(f_string_empty_s, 0, 0, 0, &delimits, 0, &state); + + assert_int_equal(state.status, F_status_set_error(F_parameter)); + } + + { + state.status = F_none; + + fl_fss_extended_list_content_read(f_string_empty_s, 0, 0, 0, &delimits, &comments, &state); + + assert_int_equal(state.status, F_status_set_error(F_parameter)); + } + + { + state.status = F_none; + + fl_fss_extended_list_content_read(f_string_empty_s, 0, 0, 0, 0, &comments, &state); assert_int_equal(state.status, F_status_set_error(F_parameter)); } @@ -136,6 +233,7 @@ void test__fl_fss_extended_list_content_read__parameter_checking(void **void_sta void test__fl_fss_extended_list_content_read__returns_data_not(void **void_state) { f_state_t state = f_state_t_initialize; + f_range_t close = f_range_t_initialize; f_range_t range = f_range_t_initialize; f_ranges_t found = f_ranges_t_initialize; f_ranges_t comments = f_ranges_t_initialize; @@ -144,7 +242,7 @@ void test__fl_fss_extended_list_content_read__returns_data_not(void **void_state { state.status = F_none; - fl_fss_extended_list_content_read(f_string_empty_s, &range, &found, &delimits, &comments, &state); + fl_fss_extended_list_content_read(f_string_empty_s, &range, &found, &close, &delimits, &comments, &state); assert_int_equal(state.status, F_data_not); } @@ -207,6 +305,7 @@ void test__fl_fss_extended_list_content_read__works(void **void_state) { f_string_static_t buffer_string = f_string_static_t_initialize; f_state_t state = f_state_t_initialize; + f_range_t close = f_range_t_initialize; f_range_t range = f_range_t_initialize; f_range_t found_object = f_range_t_initialize; f_ranges_t found = f_ranges_t_initialize; @@ -257,7 +356,7 @@ void test__fl_fss_extended_list_content_read__works(void **void_state) { state.status = F_none; if (status_object == F_fss_found_object) { - fl_fss_extended_list_content_read(buffer_string, &range, &found, &delimits, &comments, &state); + fl_fss_extended_list_content_read(buffer_string, &range, &found, &close, &delimits, &comments, &state); assert_true(state.status == F_fss_found_content || state.status == F_data_not);