public void CanMatchSuccess() { var request = new Request { Name = "Steffen", EMail = "*****@*****.**" }; var result = Validation.ValidateInput(request); result.Match( (x, msgs) => { request.ShouldBeEquivalentTo(x); }, msgs => { throw new Exception("wrong match case"); }); }
public void CanCreateSuccess() { var request = new Request { Name = "Steffen", EMail = "*****@*****.**" }; var result = Validation.ValidateInput(request); request.ShouldBeEquivalentTo(result.SucceededWith()); }