milvus/internal/util/grpcclient/client_test.go
zhenshan.cao af22977cd3
Fixbug: grpc connection is closed by mistake (#12307)
Signed-off-by: zhenshan.cao <zhenshan.cao@zilliz.com>
2021-12-03 15:15:32 +08:00

20 lines
335 B
Go

package grpcclient
import (
"testing"
"github.com/stretchr/testify/assert"
)
func TestClientBase_SetRole(t *testing.T) {
base := ClientBase{}
expect := "abc"
base.SetRole("abc")
assert.Equal(t, expect, base.GetRole())
}
func TestClientBase_GetRole(t *testing.T) {
base := ClientBase{}
assert.Equal(t, "", base.GetRole())
}