-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
[usage] Fix flaky test for ListWorkspacesByID #10818
Conversation
Well, this just failed on that exact issue so this is definitely not the fix.. :P |
/hold |
3e87b6c
to
b3a11a9
Compare
Found the problem. We created the connection at the start of the test, but re-used it for sub-tests. This meant the hooks didn't run properly. |
/unhold |
What do you mean by hooks in this context? |
https://github.com/gitpod-io/gitpod/blob/main/components/usage/pkg/db/conn.go#L75 - the |
Hmm, main still fails on the 2^16 test. Trying to reproduce. https://werft.gitpod-dev.com/job/gitpod-build-main.3638 |
Description
Sometimes (~15/100 from my repeated runs), the DB cleanup hook post tests would conflict with the data creation and would cause the tests to fail due to the exact missing IDs. Generating new random IDs hasn't failed in my test runs.
How to test
Unit tests
Release Notes
Documentation
NONE