diff options
author | Christian Franke <chris@opensourcerouting.org> | 2013-09-16 21:23:57 +0200 |
---|---|---|
committer | Christian Franke <chris@opensourcerouting.org> | 2014-01-08 00:49:41 +0100 |
commit | fdc8614c306e5b61224d1ab4b63c00c558dbb07e (patch) | |
tree | 609374c0cafcba1e4f2bf6bd3dd44ae477b5265b /tests/test-commands.c | |
parent | d30eb038466ae3d14862df08bf58ee80c00bf311 (diff) |
lib/command.c: rewrite command matching/parsing
Add support for keyword commands.
Signed-off-by: Christian Franke <chris@opensourcerouting.org>
Diffstat (limited to 'tests/test-commands.c')
-rw-r--r-- | tests/test-commands.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/tests/test-commands.c b/tests/test-commands.c index e2f40c6a..18b3b50d 100644 --- a/tests/test-commands.c +++ b/tests/test-commands.c @@ -233,8 +233,6 @@ test_init(void) cmd->daemon = 0; cmd->func = test_callback; } - sort_node(); - test_load(); vty_init_vtysh(); } @@ -340,8 +338,8 @@ test_run(struct prng *prng, struct vty *vty, const char *cmd, unsigned int edit_ { for (j = 0; j < vector_active(descriptions); j++) { - struct desc *cmd = vector_slot(descriptions, j); - printf(" '%s' '%s'\n", cmd->cmd, cmd->str); + struct cmd_token *cmd = vector_slot(descriptions, j); + printf(" '%s' '%s'\n", cmd->cmd, cmd->desc); } vector_free(descriptions); } |