public void simpleForceCaptureWithToken()
 {
     forceCapture forcecapture = new forceCapture();
     forcecapture.amount = 106;
     forcecapture.orderId = "12344";
     forcecapture.orderSource = orderSourceType.ecommerce;
     cardTokenType token = new cardTokenType();
     token.litleToken = "123456789101112";
     token.expDate = "1210";
     token.cardValidationNum = "555";
     token.type = methodOfPaymentTypeEnum.VI;
     forcecapture.token = token;
     forceCaptureResponse response = litle.ForceCapture(forcecapture);
     Assert.AreEqual("Approved", response.message); ;
 }
Exemplo n.º 2
0
        public void test60()
        {
            authorization auth = new authorization();
            auth.orderId = "60";
            auth.amount = 15000;
            auth.orderSource = orderSourceType.ecommerce;
            cardTokenType token = new cardTokenType();
            token.litleToken = "1712999999999999";
            token.expDate = "1112";
            auth.token = token;

            authorizationResponse response = litle.Authorize(auth);
            Assert.AreEqual("823", response.response);
            Assert.AreEqual("Token was invalid", response.message);
        }
 public void simpleCaptureGivenAuthWithTokenAndSpecialCharacters()
 {
     captureGivenAuth capturegivenauth = new captureGivenAuth();
     capturegivenauth.amount = 106;
     capturegivenauth.orderId = "<'&\">";
     authInformation authInfo = new authInformation();
     DateTime authDate = new DateTime(2002, 10, 9);
     authInfo.authDate = authDate;
     authInfo.authCode = "543216";
     authInfo.authAmount = 12345;
     capturegivenauth.authInformation = authInfo;
     capturegivenauth.orderSource = orderSourceType.ecommerce;
     cardTokenType cardtoken = new cardTokenType();
     cardtoken.litleToken = "123456789101112";
     cardtoken.expDate = "1210";
     cardtoken.cardValidationNum = "555";
     cardtoken.type = methodOfPaymentTypeEnum.VI;
     capturegivenauth.token = cardtoken;
     captureGivenAuthResponse response = litle.CaptureGivenAuth(capturegivenauth);
     Assert.AreEqual("Approved", response.message);
 }