summaryrefslogtreecommitdiff
path: root/tests/unit/core
diff options
context:
space:
mode:
authorSébastien Helleu <flashcode@flashtux.org>2020-01-27 22:23:55 +0100
committerSébastien Helleu <flashcode@flashtux.org>2020-01-27 23:04:24 +0100
commita6a6fb74c209a01f36b5114a1c323f641c6e927c (patch)
tree5de5a43307c2666bf7dc27d935f541fe7f5081e8 /tests/unit/core
parent2839dc7ddf03a8d45f1f3fa694c13e053f5c65e2 (diff)
downloadweechat-a6a6fb74c209a01f36b5114a1c323f641c6e927c.zip
tests: add eval tests on conditions with leading and trailing spaces (ignored)
Diffstat (limited to 'tests/unit/core')
-rw-r--r--tests/unit/core/test-core-eval.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/unit/core/test-core-eval.cpp b/tests/unit/core/test-core-eval.cpp
index e790b1ad0..24213c21b 100644
--- a/tests/unit/core/test-core-eval.cpp
+++ b/tests/unit/core/test-core-eval.cpp
@@ -98,6 +98,7 @@ TEST(CoreEval, EvalCondition)
WEE_CHECK_EVAL("0", "");
WEE_CHECK_EVAL("0", "0");
WEE_CHECK_EVAL("0", "1 == 2");
+ WEE_CHECK_EVAL("0", " 1 == 2 ");
WEE_CHECK_EVAL("0", "==1");
WEE_CHECK_EVAL("0", "1 >= 2");
WEE_CHECK_EVAL("0", "2 <= 1");
@@ -162,6 +163,7 @@ TEST(CoreEval, EvalCondition)
WEE_CHECK_EVAL("1", "123");
WEE_CHECK_EVAL("1", "abc");
WEE_CHECK_EVAL("1", "2 == 2");
+ WEE_CHECK_EVAL("1", " 2 == 2 ");
WEE_CHECK_EVAL("1", "==0");
WEE_CHECK_EVAL("1", "2 >= 1");
WEE_CHECK_EVAL("1", "1 <= 2");