Esempio n. 1
0
        public void CheckTransaction_GivenNullPaymentId_ShouldThrowAnExceptionOfTypeArgumentNullException()
        {
            CieloService cieloService = new CieloService();

            cieloService.Invoking(c => c.CheckTransaction(paymentId: null)).ShouldThrow <ArgumentNullException>();
        }
Esempio n. 2
0
        public void CancelPartialTransaction_GivenFakeMerchantOrderId_ShouldThrowAnExceptionOfTypeResponseException()
        {
            CieloService cieloService = new CieloService();

            cieloService.Invoking(c => c.CancelTransaction(merchantOrderId: "123123", amount: 20m)).ShouldThrow <ResponseException>();
        }
Esempio n. 3
0
        public void CapturePartialTransaction_GivenFakePaymentId_ShouldThrowAnExceptionOfTypeResponseException()
        {
            CieloService cieloService = new CieloService();

            cieloService.Invoking(c => c.CaptureTransaction(Guid.Parse("55158bb3-2bb9-4e76-a92b-708b51245f4b"), 20.00m)).ShouldThrow <ResponseException>();
        }
Esempio n. 4
0
        public void CancelTransaction_GivenNoOrderId_ShouldThrowAnExceptionOfTypeArgumentNullException()
        {
            CieloService cieloService = new CieloService();

            cieloService.Invoking(c => c.CancelTransaction(merchantOrderId: "")).ShouldThrow <ArgumentNullException>();
        }