Skip to content

fix(coderd/provisionerdserver): fix test flake in TestHeartbeat #11808

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Jan 25, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
testutil ctx with timeout
  • Loading branch information
johnstcn committed Jan 25, 2024
commit 7f42388005c917a38fd60f5c9521dc500079505a
3 changes: 1 addition & 2 deletions coderd/provisionerdserver/provisionerdserver_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,7 @@ func TestHeartbeat(t *testing.T) {
t.Parallel()

numBeats := 3
ctx, cancel := context.WithCancel(context.Background())
t.Cleanup(cancel)
ctx := testutil.Context(t, testutil.WaitShort)
heartbeatChan := make(chan struct{})
heartbeatFn := func(hbCtx context.Context) error {
t.Logf("heartbeat")
Expand Down