Files
baseapi/platformapi/ebaiapi/im_test.go
richboo111 5f94e94d6d 1
2023-10-27 15:40:30 +08:00

41 lines
840 B
Go

package ebaiapi
import (
"fmt"
"testing"
)
func TestGetStoreImStatus(t *testing.T) {
data, err := api.GetStoreIMStatus("1157916361")
if err != nil {
t.Errorf("%v", err)
}
t.Log(data)
}
func TestAPI_UpdateIMStatus(t *testing.T) {
err := api.UpdateIMStatus("1157916361", ImStatusOpen)
fmt.Printf("err=%v", err)
}
func TestSendMsg(t *testing.T) {
err := api.BusinessSendMsg(&BusinessSendMsgReq{
PlatformShopId: "1157916361",
BizType: IMType,
SubBizType: SubTypeDef,
Payload: BusinessMsgPayload{
GroupId: "$2$13205337818$PNM",
ReceiverIds: []string{"301157916361", "10154538612", "321921188187760"},
Content: "{\"text\": \"现在是20231027 10:04:44\"}",
ContentType: "1",
},
})
fmt.Println(err)
}
func TestNew(t *testing.T) {
a := 1698388286149
b := int(a / 1000)
fmt.Println(b)
}