Skip to content

chore: add webhook tests for notification subsystem #13942

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
Jul 19, 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
Next Next commit
Extend wait period for test; drive-by fix for possibly flaky test
Signed-off-by: Danny Kopping <danny@coder.com>
  • Loading branch information
dannykopping committed Jul 18, 2024
commit 5db00ce77c6446d3e54e6262a6398980c91617f8
5 changes: 3 additions & 2 deletions coderd/notifications/metrics_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -263,9 +263,10 @@ func TestPendingUpdatesMetric(t *testing.T) {
interceptor.proceed.Broadcast()

// Validate that the store synced the expected number of updates.
require.Eventually(t, func() bool {
require.Eventuallyf(t, func() bool {
return syncer.sent.Load() == 1 && syncer.failed.Load() == 1
}, testutil.WaitShort, testutil.IntervalFast)
}, testutil.WaitLong, testutil.IntervalFast,
"sent: %d, failed: %d", syncer.sent.Load(), syncer.failed.Load())

// Wait for the updates to be synced and the metric to reflect that.
require.Eventually(t, func() bool {
Expand Down