Test runner run with watch node --test --watch
swallows errors in before
, after
blocks
#50355
Labels
test_runner
Issues and PRs related to the test runner subsystem.
Version
v20.8.1
Platform
Darwin adonai 22.6.0 Darwin Kernel Version 22.6.0: Fri Sep 15 13:41:28 PDT 2023; root:xnu-8796.141.3.700.8~1/RELEASE_ARM64_T6000 x86_64
Subsystem
No response
What steps will reproduce the bug?
issue.mjs
node --test --watch issue.mjs
How often does it reproduce? Is there a required condition?
reproduces every time
What is the expected behavior? Why is that the expected behavior?
I expect to see the error and stacktrace in the output. If you do not run the test in
watch
mode, the error is not swallowed and the output looks like:What do you see instead?
I get output (notice no exception or stack trace):
Additional information
If the Error is thrown in
it
,describe
,beforeEach
, orafterEach
it does show as expected in output. The problem seems to be confined tobefore
andafter
blocks.The text was updated successfully, but these errors were encountered: