14 lines
377 B
JavaScript
Raw Normal View History

var child_process = require("child_process");
// restarts the test forever, that is, until an issue is detected
var count = 0;
while (true) {
console.log("[ #" + ++count + " ]\n");
2018-02-12 19:17:50 +01:00
var res = child_process.spawnSync("node", [ __dirname ], { stdio: "inherit" });
if (res.status !== 0)
throw Error("exited with " + res.status);
if (res.error)
throw res.error;
}