aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeels Hofmeyr <neels@hofmeyr.de>2017-12-15 20:41:28 +0100
committerNeels Hofmeyr <neels@hofmeyr.de>2017-12-18 04:37:46 +0100
commit41eec760c14a594042daab768e85e4a04d20dfc4 (patch)
treed14d2ec957c3f297b089b22c640f7d468c15067c
parent6115231b49382c6b21677c8ec985f61af93383c3 (diff)
ctrl_test: add two more current parsing bugs to prep for fix
-rw-r--r--tests/ctrl/ctrl_test.c16
-rw-r--r--tests/ctrl/ctrl_test.ok18
2 files changed, 34 insertions, 0 deletions
diff --git a/tests/ctrl/ctrl_test.c b/tests/ctrl/ctrl_test.c
index e25929c2..b1d4f237 100644
--- a/tests/ctrl/ctrl_test.c
+++ b/tests/ctrl/ctrl_test.c
@@ -154,6 +154,22 @@ static const struct one_test test_messages_list[] = {
"ERROR 1 Command not found",
},
+ { "GET 1 var\ti\table",
+ {
+ .type = CTRL_TYPE_GET,
+ .id = "1",
+ .variable = "var\ti\table", /* current bug */
+ },
+ "ERROR 1 Command not found",
+ },
+ { "GET 1 var\ri\rable",
+ {
+ .type = CTRL_TYPE_GET,
+ .id = "1",
+ .variable = "var\ri\rable", /* current bug */
+ },
+ "ERROR 1 Command not found",
+ },
{ "GET 1 variable value",
{
.type = CTRL_TYPE_GET,
diff --git a/tests/ctrl/ctrl_test.ok b/tests/ctrl/ctrl_test.ok
index 210c5997..4a3a1696 100644
--- a/tests/ctrl/ctrl_test.ok
+++ b/tests/ctrl/ctrl_test.ok
@@ -34,6 +34,24 @@ reply = '(null)'
handling:
replied: 'ERROR 1 Command not found'
ok
+test: 'GET 1 var\ti\table'
+parsing:
+id = '1'
+variable = 'var\ti\table'
+value = '(null)'
+reply = '(null)'
+handling:
+replied: 'ERROR 1 Command not found'
+ok
+test: 'GET 1 var\ri\rable'
+parsing:
+id = '1'
+variable = 'var\ri\rable'
+value = '(null)'
+reply = '(null)'
+handling:
+replied: 'ERROR 1 Command not found'
+ok
test: 'GET 1 variable value'
parsing:
id = '1'