summaryrefslogtreecommitdiffstats
path: root/tests/vty/vty_transcript_test.c
Commit message (Collapse)AuthorAgeFilesLines
* vty: tests: Verify incomplete optional parameters are passed to vty funcsPau Espin Pedrol2019-06-141-0/+9
| | | | | | | | The test shows that in the case were "single0 on" is executed, VTY function should return complete "single0 one" but it doesn't. Related: OS#4045 Change-Id: Ib5b9dc07e2b280dc95011b3926afb1d490cadd81
* vty: enable optional-multi-choice syntax: [(one|two)]Neels Hofmeyr2019-02-041-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | Since very recently we sensibly handle commands like cmd ([one]|[two]|[three]) as optional multi-choice arguments. In addition, support the more obvious syntax of cmd [(one|two|three)] Internally, the tokens are mangled to [one] [two] and [three], which is how the rest of the code detects optional args, and makes sense in terms of UI: > cmd ? [one] [two] [three] (i.e. optional arguments are always shown in braces in '?' listings) Before this patch, commands defined with a syntax like [(one|two)], would lead to an assertion (shows as "multiple") during program startup. Change-Id: I952b3c00f97e2447f2308b0ec6f5f1714692b5b2
* add generic vty_transcript_test.c, vty_transcript_test.vtyNeels Hofmeyr2019-02-041-0/+230
I want to tweak general VTY features and need to cover with a transcript test to show the differences. Start by showing the current situation of optional and multi-choice arguments. Change-Id: I5a79c83fabd02aba6406b6e0d620969c4bd0cc1d