Fix a few issues

* Set coverage env variables before mocha requires
* Ensure output buffer has finished writing before calling `async()`
Merge pull request #10 from joshuarubin/patch-1

Fix coverage env variable and coverage output buffer flushing