From 16bbd0a2e072bafea1dc254fbbcf86768fb3ea48 Mon Sep 17 00:00:00 2001
From: 啊鑫 <t2856754968@163.com>
Date: 星期一, 18 十一月 2024 14:57:18 +0800
Subject: [PATCH] 钉钉推送消息,通过机器人发送到个人
---
src/test/java/com/gs/dingtalk/DeviceReceivingApplicationTests.java | 30 ++++++++++++++++++++++++++++++
1 files changed, 30 insertions(+), 0 deletions(-)
diff --git a/src/test/java/com/gs/dingtalk/DeviceReceivingApplicationTests.java b/src/test/java/com/gs/dingtalk/DeviceReceivingApplicationTests.java
index aaba91d..8de1248 100644
--- a/src/test/java/com/gs/dingtalk/DeviceReceivingApplicationTests.java
+++ b/src/test/java/com/gs/dingtalk/DeviceReceivingApplicationTests.java
@@ -1,7 +1,10 @@
package com.gs.dingtalk;
import com.gs.dingtalk.config.URLEncoder;
+import com.gs.dingtalk.service.SendDingtalkService;
+import com.gs.dingtalk.service.SimpleExample;
import org.junit.jupiter.api.Test;
+import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import java.math.BigDecimal;
@@ -10,6 +13,12 @@
@SpringBootTest
class DeviceReceivingApplicationTests {
+
+ @Autowired
+ private SimpleExample simpleExample;
+
+ @Autowired
+ private SendDingtalkService sendDingtalkService;
@Test
void contextLoads() {
@@ -30,4 +39,25 @@
String encode = URLEncoder.encode("");
System.out.println(encode);
}
+
+ @Test
+ void getPhone() throws Exception {
+ sendDingtalkService.getDingTalkUserId();
+ }
+
+ @Test
+ void sendDingTalk() throws Exception {
+ sendDingtalkService.sendDingTalkFiveMinute();
+ }
+
+ @Test
+ void sendDingTalkthirtyMinute() throws Exception {
+ sendDingtalkService.sendDingTalkthirtyMinute();
+ }
+
+ //chatSendMessage
+ @Test
+ void chatSendMessage() throws Exception {
+ sendDingtalkService.chatSendMessage();
+ }
}
--
Gitblit v1.9.3