mirror of
https://gitee.com/binary/weixin-java-tools.git
synced 2026-03-10 00:13:40 +08:00
🆕 #252 实现图文消息留言管理的五个接口,包括标记及取消评论为精选、删除评论、添加及删除回复等接口
This commit is contained in:
@@ -9,9 +9,7 @@ import me.chanjar.weixin.mp.bean.comment.WxMpCommentListVo;
|
||||
import org.testng.annotations.Guice;
|
||||
import org.testng.annotations.Test;
|
||||
|
||||
import static me.chanjar.weixin.mp.enums.WxMpApiUrl.Comment.LIST;
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
import static org.mockito.Matchers.any;
|
||||
import static org.mockito.Matchers.anyString;
|
||||
import static org.mockito.Mockito.doReturn;
|
||||
import static org.mockito.Mockito.spy;
|
||||
@@ -74,4 +72,29 @@ public class WxMpCommentServiceImplTest {
|
||||
|
||||
assertThat(commentListVo.getComment().get(0).getReply()).isNotNull();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testMarkElect() throws WxErrorException {
|
||||
this.wxService.getCommentService().markElect("1000000001", null, 1L);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testUnmarkElect() throws WxErrorException {
|
||||
this.wxService.getCommentService().unmarkElect("1000000001", null, 1L);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testDelete() throws WxErrorException {
|
||||
this.wxService.getCommentService().delete("1000000001", null, 1L);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testReplyAdd() throws WxErrorException {
|
||||
this.wxService.getCommentService().replyAdd("1000000001", null, 1L, "haha");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testReplyADelete() throws WxErrorException {
|
||||
this.wxService.getCommentService().replyDelete("1000000001", null, 1L);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user