From f2519da214d97a9b1abee8c138abaeefa237b7f6 Mon Sep 17 00:00:00 2001 From: Timur Shemsedinov Date: Wed, 19 Jul 2023 03:22:48 +0300 Subject: [PATCH] fix: return number as test exit code PR-URL: https://github.com/metarhia/metatests/pull/273 --- test/no-reporter-test.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/no-reporter-test.js b/test/no-reporter-test.js index 195cc3e9..bcae2017 100644 --- a/test/no-reporter-test.js +++ b/test/no-reporter-test.js @@ -17,7 +17,7 @@ if (process.argv[2] === 'child-success') { test.end(); metatests.runner.instance.on('finish', hasFailures => { // this test must succeed if test has 'error' - the above end-after-end - process.exit(!hasFailures); + process.exit(hasFailures ? 0 : 1); }); } else { test.plan(2);