2023-06-30 09:45:02 +08:00
|
|
|
package fcm
|
|
|
|
|
|
|
|
|
|
import (
|
|
|
|
|
"context"
|
2023-07-03 14:12:29 +08:00
|
|
|
"testing"
|
|
|
|
|
|
2023-07-03 16:29:22 +08:00
|
|
|
"github.com/stretchr/testify/assert"
|
|
|
|
|
|
2023-06-30 09:45:02 +08:00
|
|
|
"github.com/OpenIMSDK/Open-IM-Server/internal/push/offlinepush"
|
|
|
|
|
"github.com/OpenIMSDK/Open-IM-Server/pkg/common/db/cache"
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
func Test_Push(t *testing.T) {
|
|
|
|
|
var redis cache.MsgModel
|
|
|
|
|
offlinePusher := NewClient(redis)
|
|
|
|
|
err := offlinePusher.Push(context.Background(), []string{"userID1"}, "test", "test", &offlinepush.Opts{})
|
|
|
|
|
assert.Nil(t, err)
|
|
|
|
|
}
|