消息服务RPC
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.

39 lines
845 B

3 years ago
  1. package msgrpc
  2. import (
  3. "testing"
  4. )
  5. func Test_SendMsg(t *testing.T) {
  6. site_id := "100064"
  7. dbname := "dev_tetele_net"
  8. business_id := "12"
  9. domainname := "http://dev6.tetele.net"
  10. msg_type := "order_create"
  11. data := map[string]string{"vv": "dd", "cc": "ss"}
  12. order_sn := ""
  13. memo := "testing"
  14. ret, err := SendMsg(site_id, dbname, business_id, domainname, msg_type, order_sn, memo, data)
  15. t.Log(ret)
  16. t.Log(err)
  17. }
  18. func Test_SendNotcie(t *testing.T) {
  19. site_id := "1058278"
  20. dbname := "shop_v2_org"
  21. domain := "http://dev6.tetele.net"
  22. user_id := "2"
  23. manager_id := "28"
  24. target_type := "product"
  25. target_id := "10"
  26. template_data := map[string]string{"order_name": "商品订单名1", "score_get": "10"}
  27. ret, err := SendNotcie(site_id, dbname, domain,user_id,manager_id,target_type,target_id,template_data)
  28. t.Log(ret)
  29. t.Log(err)
  30. }