callback to run test conditions and trigger done() of mocha

The previous commit cannot handle asynchronous controller.
Please kindly consider if to add a callback in each controller is a solution.