redis replace go redis

pull/455/head
Gordon 3 years ago committed by Xinwei Xiong(cubxxw-openim)
parent 6e088f1eb8
commit 7a5c8323df

@ -2,6 +2,7 @@ package db
import ( import (
pbChat "Open_IM/pkg/proto/chat" pbChat "Open_IM/pkg/proto/chat"
"Open_IM/pkg/proto/sdk_ws"
"context" "context"
"flag" "flag"
"fmt" "fmt"
@ -46,9 +47,11 @@ func Test_HGetAll(t *testing.T) {
} }
func Test_NewSetMessageToCache(t *testing.T) { func Test_NewSetMessageToCache(t *testing.T) {
var msg pbChat.MsgDataToMQ var msg pbChat.MsgDataToMQ
var data server_api_params.MsgData
uid := "test_uid" uid := "test_uid"
msg.MsgData.Seq = 11 data.Seq = 11
msg.MsgData.ClientMsgID = "23jwhjsdf" data.ClientMsgID = "23jwhjsdf"
msg.MsgData = &data
messageList := []*pbChat.MsgDataToMQ{&msg} messageList := []*pbChat.MsgDataToMQ{&msg}
err := DB.NewSetMessageToCache(messageList, uid, "test") err := DB.NewSetMessageToCache(messageList, uid, "test")
assert.Nil(t, err) assert.Nil(t, err)

Loading…
Cancel
Save