mirror of
https://gitee.com/binary/weixin-java-tools.git
synced 2025-11-03 05:41:46 +08:00
微信支付增加获取微信的请求和响应数据的方法getWxApiData(),方便使用者获取使用该数据
This commit is contained in:
@ -53,6 +53,7 @@ public class WxPayServiceAbstractImplTest {
|
||||
.outTradeNo("1111112")
|
||||
.build());
|
||||
this.logger.info(result.toString());
|
||||
this.logger.warn(this.payService.getWxApiData().toString());
|
||||
}
|
||||
|
||||
@Test
|
||||
|
||||
@ -12,11 +12,16 @@ import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
|
||||
public class ApiTestModule implements Module {
|
||||
private static final String TEST_CONFIG_XML = "test-config.xml";
|
||||
|
||||
@Override
|
||||
public void configure(Binder binder) {
|
||||
try (InputStream is1 = ClassLoader.getSystemResourceAsStream("test-config.xml")) {
|
||||
XmlWxPayConfig config = this.fromXml(XmlWxPayConfig.class, is1);
|
||||
try (InputStream inputStream = ClassLoader.getSystemResourceAsStream(TEST_CONFIG_XML)) {
|
||||
if (inputStream == null) {
|
||||
throw new RuntimeException("测试配置文件【" + TEST_CONFIG_XML + "】未找到");
|
||||
}
|
||||
|
||||
XmlWxPayConfig config = this.fromXml(XmlWxPayConfig.class, inputStream);
|
||||
WxPayService wxService = new WxPayServiceImpl();
|
||||
wxService.setConfig(config);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user