unit testing - AngularJS Controller As Jasmine test with mock service with promise -


I am creating an exam for angular controller and I want to create a fake service that promises me solution But it does not work with as the controller . How can I do this with any idea?

Manage this to work from injection into workspace although my controller does not inject the code ( Bit wierd, but how it has been done by a pluralSight VC by John Daddy).

Then I can call my method as scope.controllerVM.do something ();

And then call the scope. $ Digest () to call method


Comments

Popular posts from this blog

sql - Find last match with latest inserted name in table -

c# - XML serialize base class without knowing derived class -

ios - Invalid IPA: missing embedded provisioning profile. Are you sure this is an ad hoc? -