From 3a58ac9fba0bfdd0d702650a46d2faeaf0240403 Mon Sep 17 00:00:00 2001 From: congqixia Date: Wed, 28 Dec 2022 20:11:30 +0800 Subject: [PATCH] Change node stop to TearDownTest (#21422) Signed-off-by: Congqi Xia --- internal/datanode/services_test.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/internal/datanode/services_test.go b/internal/datanode/services_test.go index b2d08513f8..1fda790e4c 100644 --- a/internal/datanode/services_test.go +++ b/internal/datanode/services_test.go @@ -89,11 +89,15 @@ func (s *DataNodeServicesSuite) SetupTest() { paramtable.SetNodeID(1) } +func (s *DataNodeServicesSuite) TearDownTest() { + s.node.Stop() + s.node = nil +} + func (s *DataNodeServicesSuite) TearDownSuite() { s.cancel() err := s.etcdCli.Close() s.Require().NoError(err) - s.node.Stop() } func (s *DataNodeServicesSuite) TestNotInUseAPIs() {