Merge branch 'main' into localcache

# Conflicts:
#	go.mod
#	go.sum
#	internal/msggateway/hub_server.go
#	internal/push/consumer_init.go
#	internal/push/offlinepush/fcm/push.go
#	internal/push/offlinepush/getui/push.go
#	internal/push/offlinepush/jpush/push.go
#	internal/push/push_handler.go
#	internal/push/push_rpc_server.go
#	internal/push/push_to_client.go
#	internal/rpc/friend/friend.go
#	internal/rpc/msg/server.go
#	internal/rpc/msg/verify.go
#	pkg/common/config/config.go
#	pkg/common/db/cache/conversation.go
#	pkg/common/db/cache/meta_cache.go
#	pkg/common/db/cache/msg.go
#	pkg/common/db/localcache/conversation.go
#	pkg/common/db/localcache/group.go
#	pkg/rpcclient/conversation.go
#	pkg/rpcclient/group.go
This commit is contained in:
withchao
2024-03-07 11:59:53 +08:00
326 changed files with 7738 additions and 3878 deletions
+4 -3
View File
@@ -33,7 +33,7 @@ func TestGetDefaultConfigPath(t *testing.T) {
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
if got := GetDefaultConfigPath(); got != tt.want {
if got, _ := GetDefaultConfigPath(); got != tt.want {
t.Errorf("GetDefaultConfigPath() = %v, want %v", got, tt.want)
}
})
@@ -49,7 +49,7 @@ func TestGetProjectRoot(t *testing.T) {
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
if got := GetProjectRoot(); got != tt.want {
if got, _ := GetProjectRoot(); got != tt.want {
t.Errorf("GetProjectRoot() = %v, want %v", got, tt.want)
}
})
@@ -105,13 +105,14 @@ func TestInitConfig(t *testing.T) {
tests := []struct {
name string
args args
config *GlobalConfig
wantErr bool
}{
// TODO: Add test cases.
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
if err := InitConfig(tt.args.configFolderPath); (err != nil) != tt.wantErr {
if err := InitConfig(tt.config, tt.args.configFolderPath); (err != nil) != tt.wantErr {
t.Errorf("InitConfig() error = %v, wantErr %v", err, tt.wantErr)
}
})