public void Test_031_MasterCard_MultiPart() { // AUTH Logger.AppendText("\r\nTest_031_MasterCard_MultiPart"); Transaction response = MasterCardToken.Authorize(50m) .WithCurrency("USD") .Execute(); Assert.IsNotNull(response); Assert.AreEqual("00", response.ResponseCode); // FIRST CAPTURE Logger.AppendText("\r\nTest_031_First_Capture"); Transaction firstCapture = response.Capture(30m) .WithMultiCapture(1, 3) .Execute(); Assert.IsNotNull(firstCapture); Assert.AreEqual("00", firstCapture.ResponseCode); // SECOND CAPTURE Logger.AppendText("\r\nTest_031_Second_Capture"); Transaction secondCapture = response.Capture(10m) .WithMultiCapture(2, 3) .Execute(); Assert.IsNotNull(secondCapture); Assert.AreEqual("00", secondCapture.ResponseCode); // THIRD CAPTURE Logger.AppendText("\r\nTest_031_Third_Capture"); Transaction thirdCapture = response.Capture(10m) .WithMultiCapture(2, 3) .Execute(); Assert.IsNotNull(thirdCapture); Assert.AreEqual("00", thirdCapture.ResponseCode); }
public void Test_032_MasterCard_Single_Shipment() { // AUTH Logger.AppendText("\r\nTest_032_MasterCard_Single_Shipment"); Transaction response = MasterCardToken.Authorize(60m) .WithCurrency("USD") .Execute(); Assert.IsNotNull(response); Assert.AreEqual("00", response.ResponseCode); // FIRST CAPTURE Logger.AppendText("\r\nTest_032_First_Capture"); Transaction firstCapture = response.Capture(60m) .WithMultiCapture(1, 1) .Execute(); Assert.IsNotNull(firstCapture); Assert.AreEqual("00", firstCapture.ResponseCode); }