August 2017
Intermediate to advanced
330 pages
7h 26m
English
This class validates the model object we are using in project:
[Fact] public void ReturnNoValidationErrorsForAGreenModel()
{
// arrange
ProductModel model = GreenProductModel.Model();
// act
IEnumerable<ValidationResult> validationResult =
model.Validate(new ValidationContext(this));
// assert
validationResult.Should().HaveCount(0);
}
This preceding test looks very similar to our MS test, nothing too exciting.
Read now
Unlock full access