[Pkg-javascript-commits] [pdf.js] 100/157: Reduce verbosity of output in test/webbrowser.js

David Prévot taffit at moszumanska.debian.org
Tue Aug 11 06:46:43 UTC 2015


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository pdf.js.

commit cc0805a9960da2cf18cc7be1201e42b4d849406b
Author: Rob Wu <rob at robwu.nl>
Date:   Fri Jul 17 23:21:35 2015 +0200

    Reduce verbosity of output in test/webbrowser.js
---
 test/webbrowser.js | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)

diff --git a/test/webbrowser.js b/test/webbrowser.js
index 297df16..d14bed6 100644
--- a/test/webbrowser.js
+++ b/test/webbrowser.js
@@ -158,22 +158,25 @@ WebBrowser.prototype = {
         return pgrepStatus === 1; // "No process matched.", per man pgrep.
       };
     }
-    function execAsyncNoStdin(cmd, silent, onExit) {
+    function execAsyncNoStdin(cmd, onExit) {
       var proc = shelljs.exec(cmd, {
         async: true,
-        silent: silent === true,
+        silent: true,
       }, onExit);
       // Close stdin, otherwise wmic won't run.
       proc.stdin.end();
     }
     var killDateStart = Date.now();
     // Note: First process' output it shown, the later outputs are suppressed.
-    execAsyncNoStdin(cmdKillAll, false, function checkAlive() {
-      execAsyncNoStdin(cmdCheckAllKilled, true, function(exitCode, stdout) {
+    execAsyncNoStdin(cmdKillAll, function checkAlive(exitCode, firstStdout) {
+      execAsyncNoStdin(cmdCheckAllKilled, function(exitCode, stdout) {
         if (isAllKilled(exitCode, stdout)) {
           callback();
         } else if (Date.now() - killDateStart > 10000) {
           // Should finish termination within 10 (generous) seconds.
+          if (firstStdout) {
+            this.log('Output of first command:\n' + firstStdout);
+          }
           if (stdout) {
             this.log('Output of last command:\n' + stdout);
           }

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/pdf.js.git



More information about the Pkg-javascript-commits mailing list