Alternative solution to #196

Based off https://github.com/visionmedia/mocha/issues/333#issuecomment-7441955

Instead of synchronously writing to stdout/stderr wait for them to drain when exit is called.

Tested on node 0.8.7, 0.8.17, 0.10.2 on Windows 7 and it fixes problems with disappearing output when node is piped/redirected within powershell.