You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
356 B
26 lines
356 B
package message
|
|
|
|
import (
|
|
"log"
|
|
"sendmsg/config"
|
|
"sendmsg/global"
|
|
"testing"
|
|
)
|
|
|
|
func TestSend(t *testing.T) {
|
|
conf, err := config.InitConfig()
|
|
if err != nil {
|
|
log.Println("[test] Failed to initialize config: ", err)
|
|
}
|
|
global.GLO_CONF = conf
|
|
|
|
m := GetType()
|
|
if !Enabled() {
|
|
return
|
|
}
|
|
m.Send(Body{
|
|
Title: "Hello",
|
|
Content: "World",
|
|
})
|
|
}
|