T
T
TekVanDo2014-10-16 15:12:01
JavaScript
TekVanDo, 2014-10-16 15:12:01

What causes an error inside angular when running a test?

When writing
beforeEach(module('tabQuestionsApp'));
Inside the test directive, the test fails with the following error:

"C:\Program Files\nodejs\node.exe" C:\Users\tek\.WebIde80\config\plugins\js-karma\js_reporter\karma-intellij\lib\intellijRunner.js --karmaPackageDir=C:\Users \tek\AppData\Roaming\npm\node_modules\karma --serverPort=8080 --urlRoot=/
minErr/<@D:/OpenServer/domains/project/web/js/appcrm/tab_questions/app/scripts/resources/angular /angular.js:78:12
loadModules/<@D:/OpenServer/domains/project/web/js/appcrm/tab_questions/app/scripts/resources/angular/angular.js:3906:15
[email protected]:/OpenServer /domains/project/web/js/appcrm/tab_questions/app/scripts/resources/angular/angular.js:325:9
[email protected]:/OpenServer/domains/project/web/js/appcrm/tab_questions/app/scripts /resources/angular/angular.js:3872:5
[email protected]:/OpenServer/domains/project/web/js/appcrm/tab_questions/app/scripts/resources/angular/angular.js:3812:11
[email protected]:/OpenServer/domains/project/web/js/appcrm /tab_questions/app/scripts/resources/angular-mocks/angular-mocks.js:2244:46
Process finished with exit code 0

module initialization looks like this:
angular.module('tabQuestionsApp', ['ngSelectable','angularFileUpload','ngCkeditor','ngSanitize']);

Attached files to karma:
files: [
                'app/scripts/resources/ng-file-upload-shim/angular-file-upload-shim.min.js',
                'app/scripts/resources/angular/angular.js',
                'app/scripts/resources/angular-mocks/angular-mocks.js',
                'app/scripts/resources/ng-file-upload/angular-file-upload.min.js',
                'app/scripts/resources/ng-ckeditor/ng-ckeditor.js',
                'app/scripts/resources/angular-sanitize/angular-sanitize.js',
                'app/scripts/resources/lodash/dist/lodash.js',
                'app/scripts/resources/ngSelectable/src/ngSelectable.js',
                'app/views/*.html',
                'app/scripts/app.js',
                'app/scripts/directives/tagSearch.js',
                'test/spec/directives/tagSearch.js'

            ],

Answer the question

In order to leave comments, you need to log in

1 answer(s)
F
FuzzyBases, 2014-10-19
@FuzzyBases

HTML templates need to be uploaded via $templateCache. Maybe because of this?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question