-
Notifications
You must be signed in to change notification settings - Fork 53
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
Clear cache users between tests #342
base: master
Are you sure you want to change the base?
Clear cache users between tests #342
Conversation
This must be done for data cases as well as server cases. Because most of the querying logic rely under the hood on the caches, when someone creates a user, it won't be persisted to the DB after the test, but the cache will not be rolled back.
I tested and it worked with this test: Would be better if some sort of test was included in this PR. |
I've added a test in f543bcc. Not sure of its value but it's something at least. |
Yeah I was thinking of the add user test that caused me to find the bug in the first place. |
f543bcc
to
dedf5a4
Compare
Alright, I amended the commit and ended up using your test file. Not the biggest fan, but it's a start and definitely better than nothing. |
I'm going to hold off merging that, there's something fishy going on with some tests :( |
This must be done for data cases as well as server cases. Because most of the querying logic rely under the hood on the caches, when someone creates a user, it won't be persisted to the DB after the test, but the cache will not be rolled back.