Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
Signed-off-by: lhy1024 <admin@liudos.us>
  • Loading branch information
lhy1024 committed Nov 24, 2023
1 parent 9832697 commit 20e3b04
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion tests/testutil.go
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,10 @@ func (s *SchedulingTestEnvironment) Cleanup() {
sche := cluster.GetSchedulingPrimaryServer()
cluster.Destroy()
testutil.Eventually(re, func() bool {
return leader.GetServer().IsClosed()
if leader != nil {
return leader.GetServer().IsClosed()
}
return true
})
testutil.Eventually(re, func() bool {
if sche != nil {
Expand Down

0 comments on commit 20e3b04

Please sign in to comment.