Esempio n. 1
0
def test_add_command_with_alias():
    commands = Commands()
    commands.add_command(Hello)

    expected = OrderedDict(hello=Hello,
                           hi=Hello,
                           hey=Hello,
                           ping=Ping,
                           help=Help)
    assert commands.get_commands() == expected
Esempio n. 2
0
def test_add_command():
    commands = Commands()
    commands.add_command(Ciao)

    expected = OrderedDict(ciao=Ciao, ping=Ping, help=Help)
    assert commands.get_commands() == expected