mirror of
https://gitee.com/binary/weixin-java-tools.git
synced 2025-08-23 22:11:40 +08:00
添加缺失的单元测试
This commit is contained in:
parent
d9d0f5403e
commit
10ce6a8920
@ -1,17 +1,15 @@
|
|||||||
package me.chanjar.weixin.mp.api.impl;
|
package me.chanjar.weixin.mp.api.impl;
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
import org.testng.Assert;
|
|
||||||
import org.testng.annotations.Guice;
|
|
||||||
import org.testng.annotations.Test;
|
|
||||||
|
|
||||||
import com.google.inject.Inject;
|
import com.google.inject.Inject;
|
||||||
|
|
||||||
import me.chanjar.weixin.mp.api.ApiTestModule;
|
import me.chanjar.weixin.mp.api.ApiTestModule;
|
||||||
import me.chanjar.weixin.mp.api.WxXmlMpInMemoryConfigStorage;
|
import me.chanjar.weixin.mp.api.WxXmlMpInMemoryConfigStorage;
|
||||||
import me.chanjar.weixin.mp.bean.tag.WxTagListUser;
|
import me.chanjar.weixin.mp.bean.tag.WxTagListUser;
|
||||||
import me.chanjar.weixin.mp.bean.tag.WxUserTag;
|
import me.chanjar.weixin.mp.bean.tag.WxUserTag;
|
||||||
|
import org.testng.Assert;
|
||||||
|
import org.testng.annotations.Guice;
|
||||||
|
import org.testng.annotations.Test;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
@ -64,6 +62,14 @@ public class WxMpUserTagServiceImplTest {
|
|||||||
Assert.assertNotNull(res);
|
Assert.assertNotNull(res);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void testBatchTagging() throws Exception {
|
||||||
|
String[] openids = new String[]{((WxXmlMpInMemoryConfigStorage) this.wxService.getWxMpConfigStorage()).getOpenid()};
|
||||||
|
boolean res = this.wxService.getUserTagService().batchTagging(this.tagId, openids);
|
||||||
|
System.out.println(res);
|
||||||
|
Assert.assertTrue(res);
|
||||||
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void testBatchUntagging() throws Exception {
|
public void testBatchUntagging() throws Exception {
|
||||||
String[] openids = new String[]{((WxXmlMpInMemoryConfigStorage) this.wxService.getWxMpConfigStorage()).getOpenid()};
|
String[] openids = new String[]{((WxXmlMpInMemoryConfigStorage) this.wxService.getWxMpConfigStorage()).getOpenid()};
|
||||||
|
Loading…
Reference in New Issue
Block a user