jonkemp / jonkemp/node-qunit-phantomjs
Test runner doesn't return correct failure code if run in node script
- Dominant language
- JavaScript
- Stars
- 37
- Forks
- 13
- PR merge metrics
- No merged PRs in 30d
Description
Take this setup for example:
- Node script that looks like this:
```
"scripts": {
"prequnit": "webpack --config ./webpack.config-qunit.js",
"qunit": "node ./scripts/runQunit.js",
}
```
The pre step compiles the necessary entry files for the tests. Then the runQunit.js file looks like this:
```
const qunit = require('node-qunit-phantomjs'); // eslint-disable-line
qunit('./src/test/resources/qunit/test1.js.html', {verbose: true});
qunit('./src/test/resources/qunit/test2.js.html', {verbose: true});
qunit('./src/test/resources/qunit/test3.js.html', {verbose: true});
```
If one of those tests fail, it prints an error to the console, but doesn't return a valid error code that would kill something like CircleCI. Is there a flag in the nodeJS implementation to cause the script to fail completely if any of the qunit calls fail?
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.