report immediate `ufuzz` failure from Pull Request (#4166)
authorAlex Lam S.L <alexlamsl@gmail.com>
Fri, 2 Oct 2020 15:43:38 +0000 (16:43 +0100)
committerGitHub <noreply@github.com>
Fri, 2 Oct 2020 15:43:38 +0000 (23:43 +0800)
test/ufuzz/job.js

index e4d9ece..20f6ee0 100644 (file)
@@ -57,7 +57,13 @@ function run() {
     function respawn() {
         console.log(stdout.replace(/[^\r\n]*\r/g, ""));
         clearInterval(log);
-        if (!iterations) spawn();
+        if (!iterations) {
+            spawn();
+        } else if (process.exitCode) {
+            tasks.forEach(function(kill) {
+                kill();
+            });
+        }
     }
 
     function trap(data) {