public void ConvertShouldConvertQuestion() { Comment item = new Comment { PostId = 123, PostType = PostType.Question, CreationDate = new DateTime(2010, 06, 23) }; CommentInfo expected = new CommentInfo { CreationDate = new DateTime(2010, 06, 23), Id = 123, IsQuestion = true }; DoConvert(item, expected); }
private void DoConvert(Comment item, CommentInfo expected) { CommentToCommentInfoConverter target = new CommentToCommentInfoConverter(); var actual = target.Convert(item); Assert.AreEqual(expected, actual); }