diff --git a/tests/internal/utils.c b/tests/internal/utils.c index fb9f8c1f2a1..6195c0e848e 100644 --- a/tests/internal/utils.c +++ b/tests/internal/utils.c @@ -278,7 +278,6 @@ void test_write_str_invalid_leading_byte() void test_write_str_special_bytes() { - struct write_str_case cases[] = { /* * Escaped leading hex (two hex, one valid unicode) @@ -288,6 +287,11 @@ void test_write_str_special_bytes() "\\u4f60\\u597d\\u4e16\\u754c", FLB_TRUE }, + { + "\xC3\xA1\x0A", 3, /* UTF-8 encoding of รก and newline */ + "\\u00e1\\n", /* Expected escaped output */ + FLB_TRUE + }, { 0 } };