- dingding callback
This commit is contained in:
16
platformapi/dingdingapi/callback_test.go
Normal file
16
platformapi/dingdingapi/callback_test.go
Normal file
@@ -0,0 +1,16 @@
|
||||
package dingdingapi
|
||||
|
||||
import "testing"
|
||||
|
||||
func TestEncrypt(t *testing.T) {
|
||||
api.RegisterCallback(nil, "token", "M3Z1b1FIXjlAWW84bEVxNENHSlZOUFJEbkAlRUZQXnE", "")
|
||||
encryptedMsg, err := api.Encrypt("hello")
|
||||
decryptedMsg, err := api.Decrypt(encryptedMsg)
|
||||
t.Log(encryptedMsg, decryptedMsg, err)
|
||||
}
|
||||
|
||||
func TestPackCallbackResult(t *testing.T) {
|
||||
api.RegisterCallback(nil, "token", "M3Z1b1FIXjlAWW84bEVxNENHSlZOUFJEbkAlRUZQXnE", "")
|
||||
success := api.PackCallbackResult("success")
|
||||
t.Log(success)
|
||||
}
|
||||
Reference in New Issue
Block a user