コード例 #1
0
ファイル: AlipayGatewayTest.cs プロジェクト: mtfgqd/ICanPay
        public void TestRefund()
        {
            var notify = (Notify)_alipayGateway.BuildRefund(new Auxiliary
            {
                OutTradeNo   = _outTradeNo,
                RefundAmount = 0.01,
                OutRefundNo  = _outTradeNo
            });

            Assert.IsTrue(notify.SubMessage.Contains("交易不存在"));
            Trace.WriteLine(Util.SerializeObject(notify));
        }
コード例 #2
0
 public void TestRefund()
 {
     Assert.Throws <GatewayException>(() =>
     {
         _alipayGateway.BuildRefund(new Auxiliary
         {
             OutTradeNo   = _outTradeNo,
             RefundAmount = 0.01,
             OutRefundNo  = _outTradeNo
         });
     });
 }