Example #1
0
            public async Task WhenGetConversationParticipantsGetsCalled()
            {
                Setup();

                AuthService.Setup(service => service.GetUserIdFromToken(It.IsAny <string>())).Returns("not a guid");

                _result = await ConversationsController.GetConversationParticipants(_conversationId);
            }
Example #2
0
            public async Task WhenGetConversationParticipantsGetsCalled()
            {
                Setup();

                AuthService.Setup(service => service.GetUserIdFromToken(It.IsAny <string>())).Returns(_userId.ToString());
                ConversationsService.Setup(service => service.GetConversationParticipants(It.IsAny <Guid>()))
                .ReturnsAsync(new Fixture().CreateMany <Guid>().ToList());

                _result = await ConversationsController.GetConversationParticipants(_conversationId);
            }