2
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2025-09-06 10:50:21 +08:00

Fix chrome-qunit-test.js wasn't exiting with the right error code.

This commit is contained in:
Guo Xiang Tan 2017-12-15 14:12:01 +08:00
parent 0f011e1c1c
commit 77fbb2306d

View file

@ -68,13 +68,13 @@ const CDP = require('chrome-remote-interface');
Runtime.evaluate({ Runtime.evaluate({
expression: `(${check_script})()` expression: `(${check_script})()`
}).then((numFails) => { }).then(numFails => {
if (numFails.result.type !== 'undefined') { if (numFails.result.type !== 'undefined') {
clearInterval(interval); clearInterval(interval);
protocol.close(); protocol.close();
chrome.kill(); chrome.kill();
if (numFails.value > 0) { if (numFails.result.value > 0) {
process.exit(1); process.exit(1);
} else { } else {
process.exit(); process.exit();