Skip to content

Instantly share code, notes, and snippets.

@chfw
Created March 15, 2016 10:52
Show Gist options
  • Save chfw/ff5fbe824d0e51bfe092 to your computer and use it in GitHub Desktop.
Save chfw/ff5fbe824d0e51bfe092 to your computer and use it in GitHub Desktop.
inject base64 in karma
for test that has a dependency on base64
Error: [$injector:unpr] Unknown provider: $base64Provider <- $base64 <- <- Xcomponent
to get rid of it,
1) include bower_components/angular-base64/angular-base64.js in karma.conf.js
2) in the test case, put this along with others
beforeEach(function(){
module('base64', /* other modules */);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment