19 lines
323 B
Go
19 lines
323 B
Go
|
package pusher
|
||
|
|
||
|
import (
|
||
|
"haitao_watcher/pkg/options"
|
||
|
"testing"
|
||
|
)
|
||
|
|
||
|
func TestAnPush_Push(t *testing.T) {
|
||
|
var opt = &options.AnPushOption{
|
||
|
Token: "LHS13BO3FGBLGBP9MFBM53R8WV32P1",
|
||
|
Channel: "06683",
|
||
|
}
|
||
|
pusher := NewAnPush(opt)
|
||
|
err := pusher.Push("测试", "这是一个测试")
|
||
|
if err != nil {
|
||
|
t.Fatal(err)
|
||
|
}
|
||
|
}
|