Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [Test]
- public void Name_HasErrorWhenNull()
- {
- new CreateTableDtoValidator().ShouldHaveValidationErrorFor(t => t.Name, (string)null);
- }
- [Test]
- public void Name_DoesNotHaveErrorWhenValid()
- {
- new CreateTableDtoValidator().ShouldNotHaveValidationErrorFor(t => t.Name, "Table 1");
- }
- [Test]
- public void Name_HasErrorWhenTooLong()
- {
- new CreateTableDtoValidator().ShouldHaveValidationErrorFor(t => t.Name, new string('a', 51));
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement