public IEnumerable <MessageViewModel> GetMessage(string userNameFrom, string userToId) { var result = messengerService.GetMessage(userNameFrom, userToId).ToList(); var mapResult = mapper.Map <List <Message>, List <MessageViewModel> >(result); return(mapResult); }
public void ConstructorNoArgumentTest() { var target = new MessengerService(); string expected = "Hello, World!"; string actual = target.GetMessage(); Assert.Equal(expected, actual); }
public void ConstructorStringArgumentTest() { string payload = "Test"; var target = new MessengerService(payload); string expected = "Hello, Test!"; string actual = target.GetMessage(); Assert.Equal(expected, actual); }