Skip to content

Commit

Permalink
backend: revert PR 201 because to make the test accurate (#204)
Browse files Browse the repository at this point in the history
  • Loading branch information
djshow832 authored Jan 31, 2023
1 parent 1af49c8 commit f388efb
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions pkg/proxy/backend/backend_conn_mgr_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -646,9 +646,8 @@ func TestGracefulCloseWhenActive(t *testing.T) {
{
proxy: func(_, _ *pnet.PacketIO) error {
ts.mp.GracefulClose()
require.Eventually(t, func() bool {
return statusNotifyClose == ts.mp.closeStatus.Load()
}, 300*time.Millisecond, 100*time.Millisecond)
time.Sleep(300 * time.Millisecond)
require.Equal(t, statusNotifyClose, ts.mp.closeStatus.Load())
return nil
},
},
Expand Down

0 comments on commit f388efb

Please sign in to comment.