public void IsCommentValid_WhenNotNullOrWhitespace_ShouldReturnTrue() { //---------------Arrange------------------- var comment = new TodoComment { Comment = "a comment" }; //---------------Act---------------------- var result = comment.IsCommentValid(); //---------------Assert----------------------- Assert.IsTrue(result); }
public void IsCommentValid_WhenNullOrWhitespace_ShouldReturnFalse(string text) { //---------------Arrange------------------- var comment = new TodoComment { Comment = text }; //---------------Act---------------------- var result = comment.IsCommentValid(); //---------------Assert----------------------- Assert.IsFalse(result); }
private bool InvalidComment(TodoComment domainModel) { return(!domainModel.IsCommentValid()); }