Ejemplo n.º 1
0
        public async Task ExecuteGroupAsync(CommandContext ctx)
        {
            string?joke = await JokesService.GetRandomJokeAsync();

            if (joke is null)
            {
                await ctx.FailAsync("cmd-err-res-none");
            }
            else
            {
                await ctx.Channel.EmbedAsync(joke, Emojis.Joy, this.ModuleColor);
            }
        }
Ejemplo n.º 2
0
 public async Task GetRandomJokeAsyncTest()
 {
     Assert.IsNotNull(await JokesService.GetRandomJokeAsync());
 }
Ejemplo n.º 3
0
        public async Task ExecuteGroupAsync(CommandContext ctx)
        {
            string joke = await JokesService.GetRandomJokeAsync();

            await this.InformAsync(ctx, joke, ":joy:");
        }