1
0
mirror of synced 2025-12-24 02:57:55 +08:00

🆕 #3405 【企业微信】增加获取已服务的外部联系人的接口

Co-authored-by: zhanyan <zhanyan.work@outlook.com>
This commit is contained in:
栈烟
2024-12-03 20:13:03 +08:00
committed by GitHub
parent 3f3c37d286
commit 56977a65ca
5 changed files with 161 additions and 23 deletions

View File

@@ -1,7 +1,13 @@
package me.chanjar.weixin.cp.api.impl;
import static org.testng.Assert.assertNotNull;
import com.google.common.collect.Lists;
import com.google.inject.Inject;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Date;
import java.util.List;
import me.chanjar.weixin.common.error.WxErrorException;
import me.chanjar.weixin.common.util.XmlUtils;
import me.chanjar.weixin.cp.api.ApiTestModule;
@@ -10,6 +16,7 @@ import me.chanjar.weixin.cp.bean.WxCpBaseResp;
import me.chanjar.weixin.cp.bean.external.*;
import me.chanjar.weixin.cp.bean.external.contact.WxCpExternalContactBatchInfo;
import me.chanjar.weixin.cp.bean.external.contact.WxCpExternalContactInfo;
import me.chanjar.weixin.cp.bean.external.contact.WxCpExternalContactListInfo;
import me.chanjar.weixin.cp.bean.external.msg.Attachment;
import me.chanjar.weixin.cp.bean.external.msg.AttachmentBuilder;
import me.chanjar.weixin.cp.bean.external.msg.Image;
@@ -22,13 +29,6 @@ import org.testng.annotations.Guice;
import org.testng.annotations.Test;
import org.testng.collections.CollectionUtils;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Date;
import java.util.List;
import static org.testng.Assert.assertNotNull;
/**
* The type Wx cp external contact service impl test.
*/
@@ -188,6 +188,19 @@ public class WxCpExternalContactServiceImplTest {
assertNotNull(result);
}
/**
* Test get contact list.
*
* @throws WxErrorException the wx error exception
*/
@Test
public void testGetContactList() throws WxErrorException {
WxCpExternalContactListInfo result =
this.wxCpService.getExternalContactService().getContactList("", 100);
System.out.println(result);
assertNotNull(result);
}
/**
* Test get corp tag list.
*