From d4220e814467a78cb4912663de9f1106e6c8f2ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Helleu?= Date: Fri, 24 Nov 2023 08:04:35 +0100 Subject: [PATCH] tests: add eval tests on "raw" and "raw_hl" with escaped prefix --- tests/unit/core/test-core-eval.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/unit/core/test-core-eval.cpp b/tests/unit/core/test-core-eval.cpp index faae52eff..0c1faac35 100644 --- a/tests/unit/core/test-core-eval.cpp +++ b/tests/unit/core/test-core-eval.cpp @@ -492,6 +492,7 @@ TEST(CoreEval, EvalExpression) /* test raw string with syntax highlighting */ WEE_CHECK_EVAL("", "${raw_hl:}"); WEE_CHECK_EVAL("test", "${raw_hl:test}"); + WEE_CHECK_EVAL("\\${", "${raw_hl:\\${"); snprintf (str_value, sizeof (str_value), "%s${info:version}%s", gui_color_get_custom (config_eval_syntax_colors[0]), @@ -551,6 +552,7 @@ TEST(CoreEval, EvalExpression) /* test raw string */ WEE_CHECK_EVAL("", "${raw:}"); WEE_CHECK_EVAL("test", "${raw:test}"); + WEE_CHECK_EVAL("\\${", "${raw:\\${"); WEE_CHECK_EVAL("${info:version}", "${raw:${info:version}}"); WEE_CHECK_EVAL("yes", "${if:${raw:test?}==${raw:test?}?yes:no}"); WEE_CHECK_EVAL("no", "${if:${raw:test?}==${raw:test}?yes:no}");