1
0
mirror of synced 2025-12-22 09:58:07 +08:00

实现企业付款的接口,暂时未调通,因缺少证书 for issue #50

This commit is contained in:
Binary Wang
2016-10-06 20:53:39 +08:00
parent a4b0fdce93
commit dabafc2a9e
5 changed files with 553 additions and 14 deletions

View File

@@ -1,5 +1,7 @@
package me.chanjar.weixin.mp.api.impl;
import java.io.File;
import org.testng.annotations.Guice;
import org.testng.annotations.Test;
@@ -8,6 +10,7 @@ import com.google.inject.Inject;
import me.chanjar.weixin.common.exception.WxErrorException;
import me.chanjar.weixin.mp.api.ApiTestModule;
import me.chanjar.weixin.mp.api.WxXmlMpInMemoryConfigStorage;
import me.chanjar.weixin.mp.bean.pay.WxEntPayRequest;
import me.chanjar.weixin.mp.bean.pay.WxRedpackResult;
import me.chanjar.weixin.mp.bean.pay.WxSendRedpackRequest;
import me.chanjar.weixin.mp.bean.pay.WxUnifiedOrderRequest;
@@ -74,4 +77,16 @@ public class WxMpPayServiceImplTest {
.tradeType("JSAPI").openid("122").outTradeNo("111111").build());
System.err.println(result);
}
/**
* Test method for {@link me.chanjar.weixin.mp.api.impl.WxMpPayServiceImpl#entPay(WxEntPayRequest, File)}.
* @throws WxErrorException
*/
@Test
public final void testEntPay() throws WxErrorException {
File keyFile = new File("E:\\dlt.p12");
WxEntPayRequest request = new WxEntPayRequest();
System.err.println(this.wxService.getPayService().entPay(request, keyFile));
}
}