1
0
mirror of synced 2025-12-21 08:30:11 +08:00

🆕 #1686 微信公众号增加对话能力(原导购助手)部分接口,如添加顾问、获取顾问信息等

This commit is contained in:
Binary Wang
2020-10-06 21:04:39 +08:00
parent 64402ab1de
commit 6948044ab9
15 changed files with 389 additions and 121 deletions

View File

@@ -0,0 +1,39 @@
package me.chanjar.weixin.mp.api.impl;
import com.google.inject.Inject;
import me.chanjar.weixin.common.error.WxErrorException;
import me.chanjar.weixin.mp.api.WxMpService;
import me.chanjar.weixin.mp.api.test.ApiTestModule;
import me.chanjar.weixin.mp.bean.guide.WxMpGuideInfo;
import org.testng.annotations.Guice;
import org.testng.annotations.Test;
import static org.assertj.core.api.Assertions.assertThat;
/**
* 单元测试.
*
* @author <a href="https://github.com/binarywang">Binary Wang</a>
* @date 2020-10-06
*/
@Guice(modules = ApiTestModule.class)
public class WxMpGuideServiceImplTest {
@Inject
protected WxMpService wxService;
@Test
public void testAddGuide() throws WxErrorException {
this.wxService.getGuideService().addGuide("abc", "", null, null);
}
@Test
public void testAddGuide_another() throws WxErrorException {
this.wxService.getGuideService().addGuide(WxMpGuideInfo.builder().account("cde").build());
}
@Test
public void testGetGuide() throws WxErrorException {
final WxMpGuideInfo guideInfo = this.wxService.getGuideService().getGuide("abc", null);
assertThat(guideInfo).isNotNull();
}
}