private Unit OnInvalidInput2(CreateOrderCmd op, ICreateOrderResult result)
 {
     result.Match(created =>
     {
         Assert.True(false);
         return(created);
     }, notcreated =>
     {
         Assert.True(false);
         return(notcreated);
     }, invalidRequest =>
     {
         Assert.False(op.IsValid().Item1);
         return(invalidRequest);
     });
     return(Unit.Default);
 }
 private Unit OnValidInputAndPaymentAccepted(CreateOrderCmd op, CreateOrderResult.ICreateOrderResult result)
 {
     result.Match(created =>
     {
         Assert.True(op.IsValid().Item1);
         return(created);
     }, notCreated =>
     {
         Assert.True(false);
         return(notCreated);
     }, invalidRequest =>
     {
         Assert.True(false);
         return(invalidRequest);
     });
     return(Unit.Default);
 }