public void CanReturnIModelStateDictionary() { // Arrange ValidatorTestObject validatorTestObject = new ValidatorTestObject { Name = "123456" }; // Act IValidationResults actual = this.validator.Validate(validatorTestObject); // Assert Assert.IsTrue(actual.ContainsKey <ValidatorTestObject>(w => w.Name)); }
public void CanReturnIModelStateDictionary() { // Arrange YummySausageSalad yummySausageSalad = new YummySausageSalad { Name = "123456" }; Validator <YummySausageSalad> validator = new Validator <YummySausageSalad>(); // Act IValidationResults actual = validator.Validate(yummySausageSalad); // Assert Assert.IsTrue(actual.ContainsKey <YummySausageSalad>(w => w.Name)); }