MCPcopy
hub / github.com/angular-ui/ui-router / workFn

Function workFn

test/angular/1.4/angular-mocks.js:2368–2385  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2366 return isSpecRunning() ? workFn() : workFn;
2367 /////////////////////
2368 function workFn() {
2369 if (currentSpec.$injector) {
2370 throw new Error('Injector already created, can not register a module!');
2371 } else {
2372 var modules = currentSpec.$modules || (currentSpec.$modules = []);
2373 angular.forEach(moduleFns, function(module) {
2374 if (angular.isObject(module) && !angular.isArray(module)) {
2375 modules.push(function($provide) {
2376 angular.forEach(module, function(value, key) {
2377 $provide.value(key, value);
2378 });
2379 });
2380 } else {
2381 modules.push(module);
2382 }
2383 });
2384 }
2385 }
2386 };
2387
2388 /**

Callers 1

angular-mocks.jsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected