tests: add eval tests with invalid values for "repeat:"

v2.8-utf8proc
Sébastien Helleu 2020-01-27 21:32:28 +01:00
parent 1914ceb74f
commit 6d9a247df3
1 changed files with 5 additions and 0 deletions

View File

@ -384,6 +384,11 @@ TEST(CoreEval, EvalExpression)
WEE_CHECK_EVAL("Hello, \x19" "F03world!",
"${revscr:${revscr:Hello, ${color:red}world!}}");
/* test repeat of string (invalid values) */
WEE_CHECK_EVAL("", "${repeat:}");
WEE_CHECK_EVAL("", "${repeat:0}");
WEE_CHECK_EVAL("", "${repeat:a,x}");
/* test repeat of string */
WEE_CHECK_EVAL("", "${repeat:-1,x}");
WEE_CHECK_EVAL("", "${repeat:0,x}");