Skip to content

Commit

Permalink
Fix flakiness for TestDoDeadlineRetry
Browse files Browse the repository at this point in the history
  • Loading branch information
alexandear committed Nov 8, 2023
1 parent dfce853 commit f7d4f61
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ func TestHostClientNegativeTimeout(t *testing.T) {
func TestDoDeadlineRetry(t *testing.T) {
t.Parallel()

tries := 0
var tries int32
done := make(chan struct{})

ln := fasthttputil.NewInmemoryListener()
Expand All @@ -160,7 +160,7 @@ func TestDoDeadlineRetry(t *testing.T) {
close(done)
break
}
tries++
atomic.AddInt32(&tries, 1)
br := bufio.NewReader(c)
(&RequestHeader{}).Read(br) //nolint:errcheck
(&Request{}).readBodyStream(br, 0, false, false) //nolint:errcheck
Expand Down

0 comments on commit f7d4f61

Please sign in to comment.