You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The default karma.conf.js list of files only includes angular-ui-router.js by default. But if during yo scaffolding you choose ngRoute you run into two grunt test problems.
A warning that angular-route.js isn't installed:
WARN [watcher]: Pattern "/Users/me/Angular/angular-ng-appgen/bower_components/angular-ui-router/release/angular-ui-router.js"
does not match any file.
And, an an ugly set of errors indicating angular-route.js is not among karma.conf.js files (a part of one error):
homeService
✖ should return welcome message
Chrome 41.0.2272 (Mac OS X 10.9.5)
Error: [$injector:modulerr] Failed to instantiate module home due to:
Error: [$injector:modulerr] Failed to instantiate module ngRoute due to:
Error: [$injector:nomod] Module 'ngRoute' is not available! You either misspelled the module name or
forgot to load it. If registering a module ensure that you specify the dependencies as the second
argument.
One simple (though not elegant) solution would be to include in the generator's karma.conf.js a reference to angular-route.js along with the default angular-ui-router.js.
Then, testing produces only a benign file not found warning which ever router you choose. Seems like a reasonable trade off when compared with the time it would take to build karma.conf.js dynamically :)
The text was updated successfully, but these errors were encountered:
The default karma.conf.js list of files only includes angular-ui-router.js by default. But if during yo scaffolding you choose ngRoute you run into two
grunt test
problems.A warning that angular-route.js isn't installed:
And, an an ugly set of errors indicating angular-route.js is not among karma.conf.js files (a part of one error):
One simple (though not elegant) solution would be to include in the generator's karma.conf.js a reference to angular-route.js along with the default angular-ui-router.js.
Then, testing produces only a benign file not found warning which ever router you choose. Seems like a reasonable trade off when compared with the time it would take to build karma.conf.js dynamically :)
The text was updated successfully, but these errors were encountered: