From b41992eda17e024dbbecb425240ab0b0a7e7de38 Mon Sep 17 00:00:00 2001 From: Bingyi Sun Date: Mon, 28 Feb 2022 11:27:54 +0800 Subject: [PATCH] Fix querycoord ut bug (#15752) Signed-off-by: sunby Co-authored-by: sunby --- internal/querycoord/impl_test.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/internal/querycoord/impl_test.go b/internal/querycoord/impl_test.go index 18b2739685..c07c169e0e 100644 --- a/internal/querycoord/impl_test.go +++ b/internal/querycoord/impl_test.go @@ -413,7 +413,7 @@ func TestGrpcTaskEnqueueFail(t *testing.T) { queryCoord, err := startQueryCoord(ctx) assert.Nil(t, err) - _, err = startQueryNodeServer(ctx) + queryNode, err := startQueryNodeServer(ctx) assert.Nil(t, err) taskIDAllocator := queryCoord.scheduler.taskIDAllocator @@ -423,6 +423,9 @@ func TestGrpcTaskEnqueueFail(t *testing.T) { queryCoord.scheduler.taskIDAllocator = failedAllocator + waitQueryNodeOnline(queryCoord.cluster, queryNode.queryNodeID) + assert.NotEmpty(t, queryCoord.cluster.onlineNodeIDs()) + t.Run("Test LoadPartition", func(t *testing.T) { status, err := queryCoord.LoadPartitions(ctx, &querypb.LoadPartitionsRequest{ Base: &commonpb.MsgBase{