from valohai_cli.cli import cli


def test_command_enumeration():
    assert 'init' in cli.list_commands(None)
    assert cli.get_command(None, 'init')

@@ -145,8 +145,645 @@
 'init')%0A
+%0A%0Adef test_recursive_command_list(runner):%0A    output = runner.invoke(cli).output%0A    assert 'Commands' in output%0A    assert 'init' in output%0A    assert 'Commands (execution' in output%0A    assert 'execution info' in output%0A    assert 'execution watch' in output%0A    assert 'execution outputs' in output%0A%0A%0Adef test_prefix_match(runner):%0A    output = runner.invoke(cli, %5B'exec'%5D).output%0A    # Matched by prefix, mapped to %60execution%60's help%0A    assert 'cli execution' in output%0A%0A%0Adef test_ambiguous_match(runner):%0A    output = runner.invoke(cli, %5B'log'%5D).output%0A    assert 'be more specific' in output%0A    assert 'login, logout' in output%0A

Improve CLI test coverage