My directory structure looks something like this:
\js
...
\models\...
...
\test
\test_runner.js
\error_test.js
...
main_tests.js
Where I have the following code in main_tests.js
:
requirejs(['test/test_runner'],function(){
console.log('Testing begins');
});
The test_runner.js
looks like this:
define('test_runner',['test/error_test'],function(){
console.log("in test_runner");
});
and the error_test.js
is like this:
define('error_test',['modules/error'],function() {
console.log('in erro_test');
});
As you might have figured out I want to run from the test_runner.js
some tests. I need main_tests.js
in order to define the dependencies for the application to be tested. I can set up the application to work(it's ember based). When I run the code for the tests it loads the test_runner.js
, but it does not execute it and it also doesn't loads its dependencies(error_test.js
).
Any thoughts why it does not do the thing?
['modules/error']function
? – claustrofob