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.
23 lines
528 B
23 lines
528 B
package tests
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"github.com/stretchr/testify/assert"
|
|
"github.com/openimsdk/open-im-server/v3/pkg/common/db/controller"
|
|
)
|
|
|
|
func TestDeleteGroupMemberHash(t *testing.T) {
|
|
mockGroupDB := new(controller.MockGroupDatabase)
|
|
|
|
testGroupMemberHash := "testGroupMemberHash"
|
|
|
|
err := mockGroupDB.DeleteGroupMemberHash(testGroupMemberHash)
|
|
assert.Nil(t, err)
|
|
|
|
nonExistentGroupMemberHash := "nonExistentGroupMemberHash"
|
|
|
|
err = mockGroupDB.DeleteGroupMemberHash(nonExistentGroupMemberHash)
|
|
assert.NotNil(t, err)
|
|
}
|