From 5364c39fd56afb0d1282a9286c7ed78b229fa2a6 Mon Sep 17 00:00:00 2001 From: nolouch Date: Wed, 2 Aug 2023 14:14:58 +0800 Subject: [PATCH] fix Signed-off-by: nolouch --- tests/integrations/mcs/tso/keyspace_group_manager_test.go | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/integrations/mcs/tso/keyspace_group_manager_test.go b/tests/integrations/mcs/tso/keyspace_group_manager_test.go index 159887c1cd2..35208e73276 100644 --- a/tests/integrations/mcs/tso/keyspace_group_manager_test.go +++ b/tests/integrations/mcs/tso/keyspace_group_manager_test.go @@ -104,7 +104,7 @@ func (suite *tsoKeyspaceGroupManagerTestSuite) TestTSOKeyspaceGroupSplit() { // Get a TSO from the keyspace group 1. var ts *pdpb.Timestamp testutil.Eventually(re, func() bool { - resp, err := request(re, ctx, suite.tsoClient, 1, suite.pdLeaderServer.GetClusterID(), 222, 1) + resp, err := request(ctx, re, suite.tsoClient, 1, suite.pdLeaderServer.GetClusterID(), 222, 1) ts = resp.GetTimestamp() return err == nil && tsoutil.CompareTimestamp(ts, &pdpb.Timestamp{}) > 0 }) @@ -124,7 +124,7 @@ func (suite *tsoKeyspaceGroupManagerTestSuite) TestTSOKeyspaceGroupSplit() { // Check the split TSO from keyspace group 2. var splitTS *pdpb.Timestamp testutil.Eventually(re, func() bool { - resp, err := request(re, ctx, suite.tsoClient, 1, suite.pdLeaderServer.GetClusterID(), 222, 2) + resp, err := request(ctx, re, suite.tsoClient, 1, suite.pdLeaderServer.GetClusterID(), 222, 2) splitTS = resp.GetTimestamp() return err == nil && tsoutil.CompareTimestamp(splitTS, &pdpb.Timestamp{}) > 0 }) @@ -132,8 +132,9 @@ func (suite *tsoKeyspaceGroupManagerTestSuite) TestTSOKeyspaceGroupSplit() { } func request( + ctx context.Context, re *require.Assertions, - ctx context.Context, client tsopb.TSOClient, count uint32, + client tsopb.TSOClient, count uint32, clusterID uint64, keyspaceID, keyspaceGroupID uint32, ) (ts *tsopb.TsoResponse, err error) { req := &tsopb.TsoRequest{