def test_type_user_valid_uppercase(discord, client): @discord.command(name="TEST USER", type=ApplicationCommandType.USER) def fn(ctx, user): return "hi user" assert client.run("TEST USER").content == "hi user"
def test_type_message_valid_uppercase(discord, client): @discord.command(name="TEST MSG", type=ApplicationCommandType.MESSAGE) def fn(ctx, message): return "message" assert client.run("TEST MSG").content == "message"
def test_provided_name(discord, client): @discord.command(name="other") def fn(ctx): return "hi" assert client.run("other").content == "hi"