mirror of https://github.com/milvus-io/milvus.git
Add unittest for distributed datacoord (#7982)
Signed-off-by: yhmo <yihua.mo@zilliz.com>pull/8051/head
parent
10321e0a1a
commit
1fd0e79add
|
@ -14,7 +14,9 @@ package grpcdatacoordclient
|
|||
import (
|
||||
"testing"
|
||||
|
||||
"github.com/milvus-io/milvus/internal/distributed/grpcconfigs"
|
||||
"github.com/milvus-io/milvus/internal/log"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"go.uber.org/zap"
|
||||
)
|
||||
|
||||
|
@ -23,4 +25,12 @@ func TestParamTable(t *testing.T) {
|
|||
|
||||
log.Info("TestParamTable", zap.Int("ClientMaxSendSize", Params.ClientMaxSendSize))
|
||||
log.Info("TestParamTable", zap.Int("ClientMaxRecvSize", Params.ClientMaxRecvSize))
|
||||
|
||||
Params.Remove("dataCoord.grpc.clientMaxSendSize")
|
||||
Params.initClientMaxSendSize()
|
||||
assert.Equal(t, Params.ClientMaxSendSize, grpcconfigs.DefaultClientMaxSendSize)
|
||||
|
||||
Params.Remove("dataCoord.grpc.clientMaxRecvSize")
|
||||
Params.initClientMaxRecvSize()
|
||||
assert.Equal(t, Params.ClientMaxRecvSize, grpcconfigs.DefaultClientMaxRecvSize)
|
||||
}
|
||||
|
|
|
@ -14,6 +14,7 @@ package grpcdatacoordclient
|
|||
import (
|
||||
"testing"
|
||||
|
||||
"github.com/milvus-io/milvus/internal/distributed/grpcconfigs"
|
||||
"github.com/milvus-io/milvus/internal/log"
|
||||
"go.uber.org/zap"
|
||||
|
||||
|
@ -31,4 +32,12 @@ func TestParamTable(t *testing.T) {
|
|||
|
||||
log.Info("TestParamTable", zap.Int("ServerMaxSendSize", Params.ServerMaxSendSize))
|
||||
log.Info("TestParamTable", zap.Int("ServerMaxRecvSize", Params.ServerMaxRecvSize))
|
||||
|
||||
Params.Remove("dataCoord.grpc.ServerMaxSendSize")
|
||||
Params.initServerMaxSendSize()
|
||||
assert.Equal(t, Params.ServerMaxSendSize, grpcconfigs.DefaultServerMaxSendSize)
|
||||
|
||||
Params.Remove("dataCoord.grpc.ServerMaxRecvSize")
|
||||
Params.initServerMaxRecvSize()
|
||||
assert.Equal(t, Params.ServerMaxRecvSize, grpcconfigs.DefaultServerMaxRecvSize)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue