Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save supasympa/a1ae796b0b5960bde8f9 to your computer and use it in GitHub Desktop.
Save supasympa/a1ae796b0b5960bde8f9 to your computer and use it in GitHub Desktop.
An example of hot to mock reource dependencies in tests as see in the video: AngularJS mocking resource dependencies in tests
beforeEach(function () {
mockAccessTokenResource = jasmine.stub();//stub of resource
module(function ($provide) {
$provide.value('AccessToken', mockAccessTokenResource);
})
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment