-
-
Notifications
You must be signed in to change notification settings - Fork 349
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
[V3] File locking issue when writing to pact file with parallel tests in Jest #599
Comments
In on mobile, but the documentation says somewhere that tests need to be run with Of course, if we can fix it, that would be even better. |
Yes we do indeed! But that's only for the current package, the v3 package should be allowed to do this |
I believe this issue will happen with any framework that parallelises tests- but Jest is the only one I am aware of. I wanted to get jest-pact to detect whether the tests were running in parallel and warn, but I couldn’t figure out a way to determine it |
Oh, I didn’t see this was v3 |
A coworker and I once chased a broken feature down to a function that said “todo: implement this method”. So I guess this is better ;) |
Ron, I can see you've been making some changes for this. I was also but haven't pushed. I'll leave the upstream lib changes for you, want me to push the updates to the JS side? FYI it was fairly easy to replicate by just duplicating more tests. |
Rust libs have been released |
@mefellows Do you know if this can be closed now? |
Yes, I believe it has been fixed - thanks and closing! |
Software versions
Please provide at least OS and version of pact-js
Issue Checklist
Please confirm the following:
Expected behaviour
Pact file is written correctly when tests are run in parallel.
Actual behaviour
Failure notice:
The error seems to be
this.pact.writePactFile(result.mockServer.id, this.opts.dir) // src/v3/pact.ts:208:23
, and likely is a file locking issue.Steps to reproduce
The text was updated successfully, but these errors were encountered: