-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
test: don't use --runInBand and improve execution performance #2005
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
Conversation
Codecov Report
@@ Coverage Diff @@
## feature/refactor-tests #2005 +/- ##
======================================================
Coverage 92.4% 92.4%
======================================================
Files 28 28
Lines 1067 1067
Branches 324 324
======================================================
Hits 986 986
Misses 77 77
Partials 4 4 Continue to review full report at Codecov.
|
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.
Good job! Let's merge this in master, we will support webpack-dev-server@3
some time after release 4
version so to avoid problem with merge and releases better refactor tests in master
@evilebottnawi I want to merge this to next branch. And I'll create a backport pr to master branch because this change has many conflicts between next and master. anyway, I cannot avoid resolving conflicts. |
@hiroppy 👍 |
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.
Feel free to merge when CI green
backport from #2005 to master branch
backport from #2005 to master branch
backport from #2005 to master branch
backport from #2005 to master branch
For Bugs and Features; did you add new tests?
modify only
Motivation / Use-Case
Currently, the test's execution performance is too slow because we select serial execution.
Project: https://github.com/webpack/webpack-dev-server/projects/1#card-22555681
In this pr, we can use parallel execution.
Result
serial execution
parallel execution
Strategy
Set the number of ports of each test
see https://github.com/webpack/webpack-dev-server/blob/feature/modify-jest/test/ports-map.js
The key is a file name and the value is the number of ports. We make it easy to change the number of ports flexibly.
globalSetup
see https://github.com/webpack/webpack-dev-server/blob/feature/modify-jest/globalSetupTest.js
We'll use many ports for parallel execution, so we have to make sure that all ports used at boot time are free.
Tests
Breaking Changes
no
Additional Info
NOTE: this pr targets #1996, not
next