Ejemplo n.º 1
0
        public async void TipShouldReturnUnknownUnit()
        {
            const string unknownUnit = "UNKNOWNS";

            SetupNxtAccount(TestConstants.SenderAccount, 1);
            var message = CreateChannelMessage($"tipper tip <@{TestConstants.RecipientAccount.SlackId}> 42 {unknownUnit}");

            await slackHandler.TipBotChannelCommand(message, slackUser, channelSession);

            slackConnectorMock.Verify(c => c.SendMessage(channelSession.Id,
                                                         It.Is <string>(input => input.Equals(MessageConstants.UnknownUnit(unknownUnit))), true));
        }
Ejemplo n.º 2
0
        public async void WithdrawShouldReturnUnknownUnit()
        {
            const string unknownUnit = "UNKNOWNS";

            SetupNxtAccount(TestConstants.SenderAccount, 1);

            await slackHandler.InstantMessageCommand($"withdraw {TestConstants.RecipientAccount.NxtAccountRs} 42 {unknownUnit}", slackUser, imSession);

            slackConnectorMock.Verify(c => c.SendMessage(imSession.Id,
                                                         It.Is <string>(input => input.Equals(MessageConstants.UnknownUnit(unknownUnit))), true));
        }