-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
vitest with prisma failing randomly in CI #6635
Comments
Can't really help without a reproduction. Maybe you are removing the prisma folder or regenerating it during a test? So when another test runs in parallel, the folder is no longer there. Try running tests with |
Hello @formatlos. Please provide a minimal reproduction using a GitHub repository or StackBlitz (you can also use examples). Issues marked with |
thanks @sheremet-va for your quick response. I did find the issue: we do some parallel, transactional testing therefore we need to run migrations within each worker. We call |
Describe the bug
We are currently migrating our test-suite from jest to vitest. Everything runs smoothly locally, but on CI (Gitlab ci with k8s runner in our k8s cluster) the tests fail randomly every second or third run.
We have almost 1000 test across 115 test files, when it fails it's 1 or 2 random testfiles having one of the following errors:
or
The files it can't find are in the node_modules folder.
We are already running with
--pool=forks
and tried different settings in regards to poolOptions, but still the same behaviour.We did also compare the modules dump of a failed and successful run (which was exactly the same).
Any ideas how to solve that?
Reproduction
Run vitest in gitlab ci with a test suite using prisma
System Info
Used Package Manager
npm
Validations
The text was updated successfully, but these errors were encountered: