mirror of
https://gitee.com/binary/weixin-java-tools.git
synced 2025-04-05 17:38:05 +08:00
🎨 优化单元测试
This commit is contained in:
parent
2769f506c6
commit
1ae00b67df
@ -67,7 +67,7 @@ public class BaseWxPayServiceImplTest {
|
||||
request.setSignType(SignType.HMAC_SHA256);
|
||||
WxPayUnifiedOrderResult result = this.payService.unifiedOrder(request);
|
||||
log.info(result.toString());
|
||||
// log.warn(this.payService.getWxApiData().toString());
|
||||
log.warn(this.payService.getWxApiData().toString());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1,11 +1,5 @@
|
||||
package com.github.binarywang.wxpay.testbase;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
import com.github.binarywang.wxpay.config.WxPayConfig;
|
||||
import com.github.binarywang.wxpay.service.WxPayService;
|
||||
import com.github.binarywang.wxpay.service.impl.WxPayServiceImpl;
|
||||
@ -13,6 +7,11 @@ import com.google.inject.Binder;
|
||||
import com.google.inject.Module;
|
||||
import com.thoughtworks.xstream.XStream;
|
||||
import me.chanjar.weixin.common.util.xml.XStreamInitializer;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
|
||||
/**
|
||||
* The type Api test module.
|
||||
@ -29,6 +28,7 @@ public class ApiTestModule implements Module {
|
||||
}
|
||||
|
||||
XmlWxPayConfig config = this.fromXml(XmlWxPayConfig.class, inputStream);
|
||||
config.setIfSaveApiData(true);
|
||||
WxPayService wxService = new WxPayServiceImpl();
|
||||
wxService.setConfig(config);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user