issue #1 添加分组管理接口-查询分组
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
package chanjarster.weixin.api;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.testng.Assert;
|
||||
import org.testng.annotations.Guice;
|
||||
import org.testng.annotations.Test;
|
||||
@@ -21,9 +23,19 @@ public class WxGroupAPITest {
|
||||
@Inject
|
||||
protected WxServiceImpl wxService;
|
||||
|
||||
public void testCreateMenu() throws WxErrorException {
|
||||
public void testGroupCreate() throws WxErrorException {
|
||||
WxGroup res = wxService.groupCreate("测试分组1");
|
||||
Assert.assertEquals(res.getName(), "测试分组1");
|
||||
}
|
||||
|
||||
@Test(dependsOnMethods="testGroupCreate")
|
||||
public void testGroupGet() throws WxErrorException {
|
||||
List<WxGroup> groupList = wxService.groupGet();
|
||||
Assert.assertNotNull(groupList);
|
||||
Assert.assertTrue(groupList.size() > 0);
|
||||
for (WxGroup g : groupList) {
|
||||
Assert.assertNotNull(g.getName());
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user