-
-
Notifications
You must be signed in to change notification settings - Fork 6.5k
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
Enable single thread mode for runner #5712
Enable single thread mode for runner #5712
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This needs a test.
Also. please update the changelog 🙂
See CI for flow error (run |
9e10710
to
63e9257
Compare
@SimenB Somehow Error ┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈ packages/jest/src/jest.js:10:17
Cannot resolve module jest-cli. |
Codecov Report
@@ Coverage Diff @@
## master #5712 +/- ##
==========================================
+ Coverage 63.65% 63.67% +0.02%
==========================================
Files 216 216
Lines 7918 7918
Branches 4 4
==========================================
+ Hits 5040 5042 +2
+ Misses 2877 2875 -2
Partials 1 1
Continue to review full report at Codecov.
|
dfe9545
to
a603c5c
Compare
docs/Configuration.md
Outdated
@@ -703,6 +703,10 @@ async runTests( | |||
): Promise<void> | |||
``` | |||
|
|||
If you need to restrict your test-runner to only run in serial rather then being | |||
exectued in paralell your class should have the static attribute `serial` to be |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we call it isSerial
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
typos:
exectued
=>executed
paralell
=>parallel
That's odd. Have you tried |
Thank you @SimenB, will try that our 👍 |
2648e46
to
0e8934e
Compare
@SimenB Thank you for your help; I installed the dependencies with a different version of yarn. As a general remark: I added unit tests but they "fail" because of a missing HasteFS that should be passed to the calls. It appeared to me as if I should have passed it through, but I was incapable of retrieving or mocking HasteFS (seems to be used in the |
ba9cb3f
to
2862c29
Compare
@@ -192,7 +192,7 @@ export default class TestScheduler { | |||
onResult, | |||
onFailure, | |||
{ | |||
serial: runInBand, | |||
serial: runInBand || testRunners[runner].isSerial, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what about serial: runInBand || Boolean(testRunners[runner].isSerial)
to ensure we always pass a boolean down?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure, that makes sense 👍
@cpojer thoughts on the comments about testing and hastefs? |
We should definitely pass the right arguments to the function calls. There is a |
Some runners for tools that can not be run in parallel need a way to specify that they should not be executed in parallel. This commits adds this functionality. Closes jestjs#5706
2862c29
to
f18a9e6
Compare
I think I mocked the right things now 👍 |
Nice! |
Awesome, only 6 to go for a shirt 😂 |
You only need 5 total for a tshirt. So one down, 4 to go. You can do it! |
Some runners for tools that can not be run in parallel need a way to specify that they should not be executed in parallel. This commits adds this functionality. Closes jestjs#5706
Some runners for tools that can not be run in parallel need a way to specify that they should not be executed in parallel. This commits adds this functionality. Closes jestjs#5706
This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Summary
Some runners for tools that can not be run in parallel need a way
to specify that they should not be executed in parallel. This commits
adds this functionality. This closes #5706
Test plan
Unit tests are included