Update Testing asynchronous calls for AngularJS