public void UpdateCommand_ShouldNotHave_ValidationErrors() { _updateCommandValidator.ShouldNotHaveValidationErrorFor(x => x.Id, Guid.NewGuid()); var ucWithGoodData = new UpdateCommand { Title = "Title", Description = "Description" }; var ucValidator = _updateCommandValidator.TestValidate(ucWithGoodData); ucValidator.ShouldNotHaveValidationErrorFor(x => x.Title); ucValidator.ShouldNotHaveValidationErrorFor(x => x.Description); }
public void UpdateCommand_ShouldNotHave_ValidationErrors(string nameValue) { _updateCommandValidator.ShouldNotHaveValidationErrorFor(x => x.Id, Guid.NewGuid()); _updateCommandValidator.ShouldNotHaveValidationErrorFor(x => x.Name, nameValue); }
public void UpdateCommand_ShouldNotHave_ValidationErrors(double widthValue, double heightValue) { _updateCommandValidator.ShouldNotHaveValidationErrorFor(x => x.Id, Guid.NewGuid()); _updateCommandValidator.ShouldNotHaveValidationErrorFor(x => x.Width, widthValue); _updateCommandValidator.ShouldNotHaveValidationErrorFor(x => x.Height, heightValue); }