From: isaacs Date: Sun, 20 May 2012 12:40:10 +0000 (-0300) Subject: test: wait for 'close' event for stdout X-Git-Tag: v0.7.9~31 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=75670d3f630cbd96cadc75c62f40747dcbf966bd;p=platform%2Fupstream%2Fnodejs.git test: wait for 'close' event for stdout At the 'exit' event, it is sometimes not done writing to stdout. --- diff --git a/test/simple/test-stdout-close-catch.js b/test/simple/test-stdout-close-catch.js index ab4342b..f517a6c 100644 --- a/test/simple/test-stdout-close-catch.js +++ b/test/simple/test-stdout-close-catch.js @@ -43,7 +43,7 @@ child.stderr.on('data', function(c) { output += c; }); -child.on('exit', function(code) { +child.on('close', function(code) { try { output = JSON.parse(output); } catch (er) {