コード例 #1
0
        public void ReturnRequestedQuote_GivenQuoteExists()
        {
            QuoteEntity foundQuote = GetTestQuote();

            SetUpTest(foundQuote);

            CommandReceivedEventArgs commandReceivedEventArgs = GetEventArgs(1);

            _quoteCommand.Process(_chatClientMock.Object, commandReceivedEventArgs);

            _chatClientMock.Verify(x => x.SendMessage(foundQuote.ToString()));
        }
コード例 #2
0
        public void ReturnRequestedQuote_GivenQuoteExists()
        {
            QuoteEntity foundQuote = GetTestQuote();

            SetUpTest(foundQuote);

            CommandReceivedEventArgs commandReceivedEventArgs = GetEventArgs(1);

            _quoteCommand.Process(_fakeChatClient, commandReceivedEventArgs);

            Assert.Equal(foundQuote.ToString(), _fakeChatClient.SentMessage);
        }