Skip to content

Commit a39c1da

Browse files
adding tests
1 parent 312fbbe commit a39c1da

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

test/SocketLabs.Test/Validation/SendValidatorTest.cs

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -338,6 +338,27 @@ public void HasMessageBody_ReturnsFalse_WhenPlainTextBodyAndHtmlBodyAndApiTempla
338338
//Assert
339339
Assert.IsFalse(actual);
340340
}
341+
342+
[TestMethod]
343+
public void HasMessageBody_ReturnsFalse_WhenPlainTextBodyAndHtmlBodyAndApiTemplateAndAmpBodyIsEmpty()
344+
{
345+
//Arrange
346+
var message = new BasicMessage
347+
{
348+
HtmlBody = string.Empty,
349+
PlainTextBody = string.Empty,
350+
ApiTemplate = null,
351+
AmpBody = string.Empty
352+
};
353+
var validator = new SendValidator();
354+
355+
//Act
356+
var actual = validator.HasMessageBody(message);
357+
358+
//Assert
359+
Assert.IsFalse(actual);
360+
}
361+
341362
#endregion
342363

343364

0 commit comments

Comments
 (0)