Exemplo n.º 1
0
        public void DeleteCreditCard_Test()
        {
            MundipaggResponse <bool> deleteCreditCardResponse = CreditCard.Delete(_createdCreditCardKey);

            Assert.IsTrue(deleteCreditCardResponse.Success);
            Assert.IsNotNull(deleteCreditCardResponse.ResponseData);
            Assert.IsNull(deleteCreditCardResponse.Error);
        }
Exemplo n.º 2
0
        public void GetCreditCard_Test()
        {
            MundipaggResponse <MundipaggCreditCardData> getCreditCardResponse = CreditCard.Get(_createdCreditCardKey);

            Assert.IsTrue(getCreditCardResponse.Success);
            Assert.IsNotNull(getCreditCardResponse.ResponseData);
            Assert.IsNull(getCreditCardResponse.Error);
        }
Exemplo n.º 3
0
        public void GetAllCreditCards_Test()
        {
            MundipaggResponse <IEnumerable <MundipaggCreditCardData> > getCreditCardsResponse = CreditCard.GetAll();

            Assert.IsTrue(getCreditCardsResponse.Success);
            Assert.IsNotNull(getCreditCardsResponse.ResponseData);
            Assert.IsNull(getCreditCardsResponse.Error);
        }
Exemplo n.º 4
0
        public void CreateCreditCard_Test()
        {
            MundipaggCreditCardData creditCardData = new MundipaggCreditCardData {
                BillingAddress = null,
                Number         = "5547157866507129",
                HolderName     = "Unit Test FC Customer",
                ExpiryMonth    = 1,
                ExpiryYear     = 18,
                CardCvv        = "422"
            };

            MundipaggResponse <string> createCreditCardResponse = CreditCard.Create(creditCardData);

            Assert.IsTrue(createCreditCardResponse.Success);
            Assert.IsNotNull(createCreditCardResponse.ResponseData);
            Assert.IsNull(createCreditCardResponse.Error);

            _createdCreditCardKey = createCreditCardResponse.ResponseData;
        }