You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Checked next-gen ES issues and syntax problems by using the same environment and/or transpiler configuration without Mocha to ensure it isn't just a feature that actually isn't supported in the environment in question or a bug in your code.
'Smoke tested' the code to be tested by running it outside the real test suite to get a better sense of whether the problem is in the code under test, your usage of Mocha, or Mocha itself
Ensured that there is no discrepancy between the locally and globally installed versions of Mocha. You can find them with: node_modules/.bin/mocha --version(Local) and mocha --version(Global). We recommend that you not install Mocha globally.
Description
Running mocha with --fail-zero and --delay options, and calling run(). The exit code is always 1, even when some tests did run.
JoshuaKGoldberg
changed the title
--fail-zero always fails the test run when --delay is also used
🐛 Bug: --fail-zero always fails the test run when --delay is also used
Dec 27, 2023
Prerequisites
faq
labelnode_modules/.bin/mocha --version
(Local) andmocha --version
(Global). We recommend that you not install Mocha globally.Description
Running mocha with --fail-zero and --delay options, and calling run(). The exit code is always 1, even when some tests did run.
Steps to Reproduce
I created a gist with the files used in the examples below: https://gist.github.com/tonimellodic/525d29054744ca6d602145b81eb57e80
Expected behavior: Running with
--fail-zero
and--delay
producesexit 0
when at least one test run.Actual behavior: Running with
--fail-zero
and--delay
always producesexit 1
.Running with
--fail-zero
only:Running with
--fail-zero
and--delay
:Reproduces how often: Always
Versions
mocha 10.1.0
node 16.13.1
MacOS 12.6.1
zsh shell
The text was updated successfully, but these errors were encountered: