fix mocha test to become async