Skip to content

fix: fix test flake introduced by #9264 #9330

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 5 commits into from
Aug 25, 2023
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
Next Next commit
change check to match suffix
Signed-off-by: Spike Curtis <spike@coder.com>
  • Loading branch information
spikecurtis committed Aug 25, 2023
commit ee0636a26c65ab844f58006c26441cd87d07e6be
3 changes: 2 additions & 1 deletion coderd/templateversions_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -311,8 +311,9 @@ func TestPatchCancelTemplateVersion(t *testing.T) {
// job gets marked Failed when there is an Error; in practice we never get to Status = Canceled
// because provisioners report an Error when canceled. We check the Error string to ensure we don't mask
// other errors in this test.
t.Logf("got version %s | %s", version.Job.Error, version.Job.Status)
return assert.NoError(t, err) &&
version.Job.Error == "canceled" &&
strings.HasSuffix(version.Job.Error, "canceled") &&
version.Job.Status == codersdk.ProvisionerJobFailed
}, testutil.WaitShort, testutil.IntervalFast)
})
Expand Down