From 78c3cebc389a2b0d426d74900a65b8656edb426d Mon Sep 17 00:00:00 2001 From: Dirk Engling Date: Mon, 26 Oct 2026 18:13:27 +0100 Subject: Third run of making variable and function names more readable, integer scans and ip parsers --- tests/t_urlencoded.c | 29 ----------------------------- 1 file changed, 29 deletions(-) (limited to 'tests/t_urlencoded.c') diff --git a/tests/t_urlencoded.c b/tests/t_urlencoded.c index 1239e6b..6e0ee31 100644 --- a/tests/t_urlencoded.c +++ b/tests/t_urlencoded.c @@ -228,33 +228,6 @@ static void case_find_keywords(void) { CHECK_INT(urlencoded_match_keyword(keywords, &p, SCAN_SEARCHPATH_PARAM), -3); } -static void case_fixed_int(void) { - char positive[] = "123"; - char negative[] = "-45"; - char trailing[] = "12a"; - int value; - - test_case("scan_fixed_int returns the count of unparsed bytes"); - CHECK_INT(scan_fixed_int(positive, 3, &value), 0); - CHECK_INT(value, 123); - - CHECK_INT(scan_fixed_int(negative, 3, &value), 0); - CHECK_INT(value, -45); - - CHECK_INT(scan_fixed_int(trailing, 3, &value), 1); - CHECK_INT(value, 12); -} - -static void case_fixed_int_bounded(void) { - char digits[] = "12345"; - int value; - - test_case("scan_fixed_int honours the length it is given"); - CHECK_INT(scan_fixed_int(digits, 3, &value), 0); - CHECK_INT(value, 123); -} - - /* The encoding direction. Which bytes survive unescaped is fixed by what existing parsers of the urlencoded full scrape expect, so these cases pin the set rather than describe a preference. */ @@ -361,8 +334,6 @@ void test_urlencoded(void) { case_raw_high_byte(); case_skipvalue(); case_find_keywords(); - case_fixed_int(); - case_fixed_int_bounded(); case_fmt_passes_safe_bytes(); case_fmt_escapes_the_rest(); case_fmt_hex_is_lower_case(); -- cgit v1.3