From b84c7d09d893ea9c3a858bc053b78ade9f55bc17 Mon Sep 17 00:00:00 2001 From: renzhiyuan <465386466@qq.com> Date: Wed, 22 Oct 2025 20:25:32 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B4=A2=E5=8A=A1=E7=B3=BB=E7=BB=9F=E6=94=AF?= =?UTF-8?q?=E8=A1=8C=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- const.go | 4 ++-- test/msg_test.go | 11 +++++------ 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/const.go b/const.go index cda16c1..aeeda61 100644 --- a/const.go +++ b/const.go @@ -43,8 +43,8 @@ const ( ) var smsBusinessWithRequestPath = map[SmsBusiness]requestPathIndex{ - SmsBusinessHs: sendSms, - SmsBusinessDefault: sendSmsHs, + SmsBusinessHs: sendSmsHs, + SmsBusinessDefault: sendSms, } type RequestWay int8 diff --git a/test/msg_test.go b/test/msg_test.go index 2a89355..dc8969c 100644 --- a/test/msg_test.go +++ b/test/msg_test.go @@ -3,26 +3,25 @@ package test import ( "context" "fmt" - "gitea.cdlsxd.cn/self-tools/l_msg_api" "testing" + + "gitea.cdlsxd.cn/self-tools/l_msg_api" ) const ( - ClientKey = "ymt" - ClientSecret = "ymt" + ClientKey = "finance" + ClientSecret = "finance" serverHost = "http://121.199.38.107:8000" local = "http://127.0.0.1:8001" ) func TestSms(t *testing.T) { - msg, err := l_msg_api.NewMessageCenter(serverHost, ClientKey, ClientSecret, "sms", "sms") + msg, err := l_msg_api.NewMessageCenter(serverHost, ClientKey, ClientSecret, "sms2", "cron_sms2") if err != nil { panic(err) } - res, err := msg.SendSms(context.TODO(), []string{"15082245107"}, `{"content": "测试"}`) fmt.Println(res, err) - } func TestAccess(t *testing.T) {