diff options
author | Neels Hofmeyr <neels@hofmeyr.de> | 2020-08-12 00:56:56 +0000 |
---|---|---|
committer | Neels Hofmeyr <neels@hofmeyr.de> | 2020-08-12 01:05:59 +0000 |
commit | 345a15f213401f1645acdb69ecd1cb1f28d63891 (patch) | |
tree | 72ad35fca96d16997c2230af89fecf1bfd9d0387 /library | |
parent | e4b0a662ca8bf61b6029552d9b5379d26ab5cf87 (diff) |
log: for VTY Unknown Command, fix weird log message
In f_vty_wait_for_prompt(), this:
testcase.stop(fail, "VTY: Unknown Command")
outputs:
failVTY: Unknown Command
The first stop() argument 'fail' is not actually a test verdict, but gets
rolled into a log output string, becoming "failVTY".
Fix that by simply using the normal pattern of setverdict() followed by
mtc.stop().
Change-Id: Id09986444de02c10b4fba582d454d54568b6e8a2
Diffstat (limited to 'library')
-rw-r--r-- | library/Osmocom_VTY_Functions.ttcn | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/library/Osmocom_VTY_Functions.ttcn b/library/Osmocom_VTY_Functions.ttcn index cb3434e6..e5f615c5 100644 --- a/library/Osmocom_VTY_Functions.ttcn +++ b/library/Osmocom_VTY_Functions.ttcn @@ -68,7 +68,8 @@ module Osmocom_VTY_Functions { [] pt.receive(pattern "[\w-]+\(*\)\# ") { }; [] pt.receive(t_vty_unknown) { if (strict) { - testcase.stop(fail, "VTY: Unknown Command"); + setverdict(fail, "VTY: Unknown Command"); + mtc.stop; } else { log("VTY: Unknown Command (ignored)"); buf := buf & rx; |