More logging in simple/test-eio-race
authorisaacs <i@izs.me>
Thu, 29 Mar 2012 15:41:04 +0000 (08:41 -0700)
committerisaacs <i@izs.me>
Thu, 29 Mar 2012 15:41:51 +0000 (08:41 -0700)
Travis-CI is failing on this test repeatedly, but other Linux systems
seem to be fine with it.  Alter the logging so it's more clear which
part is timing out.

test/simple/test-eio-race.js

index cbe95c65b4d30c3fdd2f53914ab573121731aeb8..558d09a9cffe0487ca6e1edeaf9cd9d62b372509 100644 (file)
@@ -36,18 +36,17 @@ function tryToKillEventLoop() {
     if (err) {
       throw new Exception('first fs.stat failed');
     } else {
-      console.log('first fs.stat succeeded ...');
       fs.stat(__filename, function(err) {
         if (err) {
           throw new Exception('second fs.stat failed');
         } else {
-          console.log('second fs.stat succeeded ...');
           console.log('could not kill event loop, retrying...');
 
           setTimeout(function() {
             if (--count) {
               tryToKillEventLoop();
             } else {
+              console.log('done trying to kill event loop');
               process.exit(0);
             }
           }, 1);
@@ -81,5 +80,6 @@ fs.open(filename, 'r', 0666, function(err, fd) {
 tryToKillEventLoop();
 
 process.on('exit', function() {
+  console.log('done with test');
   assert.ok(pos > 10000);
 });