Skip to content

Commit

Permalink
test: use sleep for waiting
Browse files Browse the repository at this point in the history
  • Loading branch information
AleksandrMatsko committed Dec 11, 2024
1 parent 13c318e commit 874069d
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions notifier/alive_watcher_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,9 +104,7 @@ func TestAliveWatcher_Start(t *testing.T) {
ctx, cancel := context.WithCancel(context.Background())
aliveWatcher.Start(ctx)

select {
case <-time.After(time.Second * 3):
cancel()
}
time.Sleep(time.Second * 3)
cancel()
})
}

0 comments on commit 874069d

Please sign in to comment.