Skip to content

fix: remove redundant flaking test #14888

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 1 commit into from
Oct 1, 2024
Merged

fix: remove redundant flaking test #14888

merged 1 commit into from
Oct 1, 2024

Conversation

ethanndickson
Copy link
Member

@ethanndickson ethanndickson commented Oct 1, 2024

Closes #14877.

I suspect this was flaking on CI as the dbtime used for the refreshed expiry was being rounded to the nearest microsecond. The time values we're comparing are always super close together. and I assume they were being compared as equal? I noticed the flakes were only occurring when the whole test was running in under 100ms, and I was unable to get the tests to fail locally, nor could I get the test to run that quickly. (It also might have been a Windows time precision issue? I only saw the flake on Windows)

Regardless, we already have a test for this in httpmw/apikey_test.go, and when I wrote this variation it was mainly just to sanity check cli tokens were getting refreshed at all - I now know all apikeys get refreshed!

I don't think we need to test it again at the coderd level, so I'm happy to get rid of it.

Copy link
Member Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

Join @ethanndickson and the rest of your teammates on Graphite Graphite

Copy link

@cdr-bot cdr-bot bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR is a hotfix and has been automatically approved.

  • ✅ Base is main or release branch
  • ✅ Has hotfix label
  • ✅ Head is from coder/coder
  • ✅ Less than 100 lines

@ethanndickson ethanndickson marked this pull request as ready for review October 1, 2024 08:59
@ethanndickson ethanndickson enabled auto-merge (squash) October 1, 2024 08:59
@ethanndickson ethanndickson merged commit 2a3a00c into main Oct 1, 2024
37 checks passed
@ethanndickson ethanndickson deleted the ethan/refresh-flake branch October 1, 2024 09:01
@github-actions github-actions bot locked and limited conversation to collaborators Oct 1, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

flake: TestAPIKey_Refresh
1 participant