Denys Otrishko
600349aaba
test: refactor process/worker exitCode tests
...
PR-URL: https://github.com/nodejs/node/pull/21739
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2018-07-14 12:36:53 +02:00
Denys Otrishko
961f6e8623
process: fix process.exitCode handling for fatalException
...
* set process.exitCode before calling 'exit' handlers so that there will
not be a situation where process.exitCode !== code in 'exit' callback
during uncaughtException handling
* don't ignore process.exitCode set in 'exit' callback when failed with
uncaughtException and there is no uncaughtException listener
PR-URL: https://github.com/nodejs/node/pull/21739
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2018-07-14 12:36:53 +02:00
Anna Henningsen
f46536be23
test: fix timeouts when running worker tests with --worker
...
These tests have been added after the original workers PR and
time out when run inside a worker by themselves.
This is needed for enabling `--worker` tests in our regular CI.
Refs: https://github.com/nodejs/build/issues/1318
PR-URL: https://github.com/nodejs/node/pull/21791
Reviewed-By: Jon Moss <me@jonathanmoss.me >
Reviewed-By: Refael Ackermann <refack@gmail.com >
2018-07-14 12:03:01 +02:00
Denys Otrishko
25fef3d8d4
workers: fix invalid exit code in parent upon uncaught exception
...
Now worker.on('exit') reports correct exit code (1) if worker has exited
with uncaught exception.
Fixes: https://github.com/nodejs/node/issues/21707
PR-URL: https://github.com/nodejs/node/pull/21713
Reviewed-By: Gus Caplan <me@gus.host >
Reviewed-By: Yuta Hiroto <hello@hiroppy.me >
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2018-07-12 09:09:01 +02:00