test(mocks): test mocks with compiled angular

Unfortunately, there people in our team (me), who are not able to use angular.* namespace prefix
when writing angular-mocks code, so we need to test it...
This commit is contained in:
Vojta Jina 2011-10-31 17:56:55 -07:00
parent 2636105c5e
commit ddf6f1143f
3 changed files with 15 additions and 0 deletions

9
angularFiles.js vendored
View file

@ -94,6 +94,15 @@ angularFiles = {
'build/docs/docs-scenario.js'
],
'jstdMocks': [
'lib/jasmine/jasmine.js',
'lib/jasmine-jstd-adapter/JasmineAdapter.js',
'build/angular.js',
'src/angular-mocks.js',
'test/matchers.js',
'test/angular-mocksSpec.js'
],
'jstdPerf': [
'lib/jasmine/jasmine.js',
'lib/jasmine-jstd-adapter/JasmineAdapter.js',

View file

@ -16,6 +16,8 @@ fs.readFile('angularFiles.js', function(err, data) {
fs.writeFile('./jsTestDriver.conf', prefix + combine(angularFiles.jstd,
angularFiles.jstdExclude));
fs.writeFile('./jsTestDriver-mocks.conf', prefix + combine(angularFiles.jstdMocks));
fs.writeFile('./jsTestDriver-scenario.conf', prefixScenario +
combine(angularFiles.jstdScenario) +
'\n\nproxy:\n- {matcher: "*", server: "http://localhost:8000"}');

4
test-mocks.sh Executable file
View file

@ -0,0 +1,4 @@
#!/bin/bash
if [ ! -e test.dissable ]; then
java -jar lib/jstestdriver/JsTestDriver.jar --tests all --config jsTestDriver-mocks.conf $@
fi