Wait for asynchronous task to finish with the completion block invoked in unit tests