Since the latest release (4.1.1), jest-puppeteer will timeout when trying to detect if a port is used. I was able to narrow it down to the changes in jest-dev-server introduced in #227.
Worked up to version: [email protected]
Stopped working in version: [email protected]
Steps to reproduce the behavior:
express server on port 3000server.port to 3000 in the jest-puppeteer.config.js filejestjest-puppeteer should be able to detect if the port is used, and the tests should pass.
https://github.com/Dilatorily/jest-puppeteer-issue
npx envinfo --system --binaries --npmPackages expect-puppeteer,jest-dev-server,jest-environment-puppeteer,jest-puppeteer,spawnd --markdown --clipboardPaste the results here:
## System:
- OS: macOS Sierra 10.12.6
- CPU: (4) x64 Intel(R) Core(TM) i7-5557U CPU @ 3.10GHz
- Memory: 2.71 GB / 16.00 GB
- Shell: 3.2.57 - /bin/bash
## Binaries:
- Node: 11.14.0 - /usr/local/bin/node
- Yarn: 1.15.2 - /usr/local/bin/yarn
- npm: 6.9.0 - /usr/local/bin/npm
- Watchman: 4.9.0 - /usr/local/bin/watchman
## npmPackages:
- jest-puppeteer: ^4.1.1 => 4.1.1
@xiaoyuhen any infos on this?
Perhaps this is what is causing the issue: https://github.com/smooth-code/jest-puppeteer/commit/59d796b59c213b53c8842f2545fbaabf09d09dd4
@sync
yeah, its a bug from this https://github.com/smooth-code/jest-puppeteer/commit/59d796b59c213b53c8842f2545fbaabf09d09dd4 commit.
I am working hard to fix it
Don鈥檛 work too hard. Take the time and don鈥檛 stress about it 鉂わ笍
it seems like we must set tcp prefixes, then wait-on package can find our server.
very sorry about the problem, it will fix on this https://github.com/smooth-code/jest-puppeteer/pull/235 PR. cc @sync @Dilatorily
Hej @xiaoyuhen, I have some issues with a local express instance using https.createServer ;
(The server itself starts but jest always show the timeout message Server has taken more than {whichever timeout duration I set up in jest-puppeteer.config.js} to start.)
(HTTP mode without certificates works fine)
As a side effect, the teardown is not invoked, and the local process continues to run after timeout.
--> Next time I launch the tests, I face listen EADDRINUSE: address already in use error.
Just wondering if this is related to this issue as well, and if #235 has been released already // is planned to be released?
(Nothing urgent on my side, just wish to know)
Hi @xiaoyuhen. In https://github.com/smooth-code/jest-puppeteer/issues/236#issuecomment-489136131, you mentioned that a patch is on its way. When do you plan to publish a fix for jest-puppeteer? Or is this fixed?
Most helpful comment
Don鈥檛 work too hard. Take the time and don鈥檛 stress about it 鉂わ笍