Exemple #1
0
            public void ReturnsErrors()
            {
                var request = new SagePay.Request.Refund.OfflineSageRefund();
                request.Transaction = new SagePay.Request.Refund.RefundRequest();
                var errors = request.Validate();

                Assert.NotEmpty(errors);
            }
Exemple #2
0
            public void SetsIsValid()
            {
                var request = new SagePay.Request.Refund.OfflineSageRefund();
                request.Transaction = RefundRequest.SampleRequest();
                var errors = request.Validate();

                Assert.Equal(0, errors.Count);
                Assert.True(request.IsValid);
            }
Exemple #3
0
            public void EmitsAResponseIfValid()
            {
                var request = new SagePay.Request.Refund.OfflineSageRefund();
                request.Transaction = RefundRequest.SampleRequest();
                request.Validate();

                var response = request.Send();
                Assert.NotNull(response);
            }