Example #1
0
        public Task <ChangeTransactionStatusResponse> CompleteTransactionAsync(Shop shop, string wsPayOrderId, string stan,
                                                                               string approvalCode, double price)
        {
            var requestData = requestFactory.CreateChangeTransactionStatusRequest(shop, wsPayOrderId, stan, approvalCode, price);

            return(wsPayClient.RequestAsync <ChangeTransactionStatusRequest, ChangeTransactionStatusResponse>(requestData, Services.Completion));
        }
Example #2
0
        public void CreateChangeTransactionStatusRequest()
        {
            var actual   = modelFactory.CreateChangeTransactionStatusRequest(RegularShop, "testShoppingCartid", "stan", "approvalCode", 15.25);
            var expected = new ChangeTransactionStatusRequest
            {
                WSPayOrderId = "testShoppingCartid",
                ShopId       = RegularShop.ShopId,
                Amount       = "1525",
                Stan         = "stan",
                ApprovalCode = "approvalCode",
                Signature    = "8c56fab77dcba8edca85cc5feb618a03"
            };

            actual.Should().BeEquivalentTo(expected);
        }