Ejemplo n.º 1
0
        public async Task GetUrbanQuoteAsync([Remainder] string searchTerm)
        {
            var quotes = await _urbanService.GetUrbanQuotesAsync(searchTerm);

            string definitions = _urbanService.ParseQuotes(quotes);

            if (definitions.Length > 0)
            {
                await ReplyAsync(definitions);
            }
            else
            {
                await ReplyAsync("No definitions found.");
            }
        }
Ejemplo n.º 2
0
 public void Parser_ShouldThrowException_WhenInputIsEmpty()
 {
     Assert.That(() => _urbanService.ParseQuotes(new UrbanResponse()), Throws.ArgumentNullException);
 }