I'm creating an InlineValidator
(from the FluentValidation nuget package/library).
var validator = new InlineValidator<Person>;validator.RuleFor(x => x.Surname).NotNull();validator.RuleSet("someRuleSet", () => { // ????? });
When I try to call the RuleSet method in there, it seems to not compile.
How can I create a RuleSet against an InlineValidator
please ?
Here's the example ruleset i'm trying...
.RuleSet("someRuleSet", () =>{ RuleFor(x => x.Name).NotNull(); RuleFor(x => x.Age).NotEqual(0);}