Commit 2bbc58fb authored by Aron Carroll's avatar Aron Carroll Committed by Randall Leeds

Add karma-ng-html2js-preprocessor

This deals with importing templates into the unit tests.
parent be1016d5
...@@ -65,7 +65,7 @@ module.exports = function(config) { ...@@ -65,7 +65,7 @@ module.exports = function(config) {
// available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
preprocessors: { preprocessors: {
'**/*.coffee': ['coffee'], '**/*.coffee': ['coffee'],
'**/*.html': ['html2js'] 'h/templates/*.html': ['ng-html2js'],
}, },
...@@ -99,6 +99,11 @@ module.exports = function(config) { ...@@ -99,6 +99,11 @@ module.exports = function(config) {
// Continuous Integration mode // Continuous Integration mode
// if true, Karma captures browsers, runs the tests and exits // if true, Karma captures browsers, runs the tests and exits
singleRun: false singleRun: false,
ngHtml2JsPreprocessor: {
stripPrefix: 'h/templates/',
moduleName: 'h.templates',
}
}); });
}; };
...@@ -14,7 +14,7 @@ class MockSession ...@@ -14,7 +14,7 @@ class MockSession
describe 'h.auth', -> describe 'h.auth', ->
beforeEach module('h.auth') beforeEach module('h.auth')
beforeEach module('auth.html') beforeEach module('h.templates')
beforeEach module ($provide) -> beforeEach module ($provide) ->
$provide.value '$timeout', sinon.spy() $provide.value '$timeout', sinon.spy()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment