@@ -12,7 +12,7 @@ describe('gulp-angular-templatecache', function () {
12
12
stream . on ( 'data' , function ( file ) {
13
13
assert . equal ( path . normalize ( file . path ) , path . normalize ( __dirname + '/templates.js' ) ) ;
14
14
assert . equal ( file . relative , 'templates.js' ) ;
15
- assert . equal ( file . contents . toString ( 'utf8' ) , 'angular.module(\'templates\').run([\'$templateCache\', function($templateCache) {$templateCache.put(\'template-a.html\',\'<h1 id="template-a">I\\\'m template A!</h1>\');\n$templateCache.put(\'template-b.html\',\'<h1 id="template-b">I\\\'m template B!</h1>\');}]);' ) ;
15
+ assert . equal ( file . contents . toString ( 'utf8' ) , 'angular.module(\'templates\').run([\'$templateCache\', function($templateCache) {$templateCache.put(\'/ template-a.html\',\'<h1 id="template-a">I\\\'m template A!</h1>\');\n$templateCache.put(\'/ template-b.html\',\'<h1 id="template-b">I\\\'m template B!</h1>\');}]);' ) ;
16
16
cb ( ) ;
17
17
} ) ;
18
18
@@ -155,7 +155,7 @@ describe('gulp-angular-templatecache', function () {
155
155
stream . on ( 'data' , function ( file ) {
156
156
assert . equal ( path . normalize ( file . path ) , path . normalize ( __dirname + '/templates.js' ) ) ;
157
157
assert . equal ( file . relative , 'templates.js' ) ;
158
- assert . equal ( file . contents . toString ( 'utf8' ) , 'angular.module(\'templates\').run([\'$templateCache\', function($templateCache) {$templateCache.put(\'tpl-a.html\',\'<h1 id="template-a">I\\\'m template A!</h1>\');}]);' ) ;
158
+ assert . equal ( file . contents . toString ( 'utf8' ) , 'angular.module(\'templates\').run([\'$templateCache\', function($templateCache) {$templateCache.put(\'/ tpl-a.html\',\'<h1 id="template-a">I\\\'m template A!</h1>\');}]);' ) ;
159
159
cb ( ) ;
160
160
} ) ;
161
161
@@ -205,7 +205,7 @@ describe('gulp-angular-templatecache', function () {
205
205
stream . on ( 'data' , function ( file ) {
206
206
assert . equal ( path . normalize ( file . path ) , path . normalize ( __dirname + '/templates.js' ) ) ;
207
207
assert . equal ( file . relative , 'templates.js' ) ;
208
- assert . equal ( file . contents . toString ( 'utf8' ) , 'angular.module(\'templates\', []).run([\'$templateCache\', function($templateCache) {$templateCache.put(\'template-a.html\',\'<h1 id="template-a">I\\\'m template A!</h1>\');}]);' ) ;
208
+ assert . equal ( file . contents . toString ( 'utf8' ) , 'angular.module(\'templates\', []).run([\'$templateCache\', function($templateCache) {$templateCache.put(\'/ template-a.html\',\'<h1 id="template-a">I\\\'m template A!</h1>\');}]);' ) ;
209
209
cb ( ) ;
210
210
} ) ;
211
211
@@ -331,7 +331,7 @@ describe('gulp-angular-templatecache', function () {
331
331
stream . on ( 'data' , function ( file ) {
332
332
assert . equal ( file . path , path . normalize ( __dirname + '/templates.js' ) ) ;
333
333
assert . equal ( file . relative , 'templates.js' ) ;
334
- assert . equal ( file . contents . toString ( 'utf8' ) , '\'use strict\'; module.exports = angular.module(\'templates\', []).run([\'$templateCache\', function($templateCache) {$templateCache.put(\'template-a.html\',\'<h1 id="template-a">I\\\'m template A!</h1>\');}]);' ) ;
334
+ assert . equal ( file . contents . toString ( 'utf8' ) , '\'use strict\'; module.exports = angular.module(\'templates\', []).run([\'$templateCache\', function($templateCache) {$templateCache.put(\'/ template-a.html\',\'<h1 id="template-a">I\\\'m template A!</h1>\');}]);' ) ;
335
335
cb ( ) ;
336
336
} ) ;
337
337
@@ -352,7 +352,7 @@ describe('gulp-angular-templatecache', function () {
352
352
stream . on ( 'data' , function ( file ) {
353
353
assert . equal ( path . normalize ( file . path ) , path . normalize ( __dirname + '/templates.js' ) ) ;
354
354
assert . equal ( file . relative , 'templates.js' ) ;
355
- assert . equal ( file . contents . toString ( 'utf8' ) , 'define([\'angular\'], function(angular) { \'use strict\'; return angular.module(\'templates\').run([\'$templateCache\', function($templateCache) {$templateCache.put(\'template-a.html\',\'<h1 id="template-a">I\\\'m template A!</h1>\');}]);});' ) ;
355
+ assert . equal ( file . contents . toString ( 'utf8' ) , 'define([\'angular\'], function(angular) { \'use strict\'; return angular.module(\'templates\').run([\'$templateCache\', function($templateCache) {$templateCache.put(\'/ template-a.html\',\'<h1 id="template-a">I\\\'m template A!</h1>\');}]);});' ) ;
356
356
cb ( ) ;
357
357
} ) ;
358
358
@@ -373,7 +373,7 @@ describe('gulp-angular-templatecache', function () {
373
373
stream . on ( 'data' , function ( file ) {
374
374
assert . equal ( path . normalize ( file . path ) , path . normalize ( __dirname + '/templates.js' ) ) ;
375
375
assert . equal ( file . relative , 'templates.js' ) ;
376
- assert . equal ( file . contents . toString ( 'utf8' ) , 'import angular from \'angular\'; export default angular.module(\'templates\').run([\'$templateCache\', function($templateCache) {$templateCache.put(\'template-a.html\',\'<h1 id="template-a">I\\\'m template A!</h1>\');}]);' ) ;
376
+ assert . equal ( file . contents . toString ( 'utf8' ) , 'import angular from \'angular\'; export default angular.module(\'templates\').run([\'$templateCache\', function($templateCache) {$templateCache.put(\'/ template-a.html\',\'<h1 id="template-a">I\\\'m template A!</h1>\');}]);' ) ;
377
377
cb ( ) ;
378
378
} ) ;
379
379
@@ -394,7 +394,7 @@ describe('gulp-angular-templatecache', function () {
394
394
stream . on ( 'data' , function ( file ) {
395
395
assert . equal ( path . normalize ( file . path ) , path . normalize ( __dirname + '/templates.js' ) ) ;
396
396
assert . equal ( file . relative , 'templates.js' ) ;
397
- assert . equal ( file . contents . toString ( 'utf8' ) , '(function(){\'use strict\';angular.module(\'templates\').run([\'$templateCache\', function($templateCache) {$templateCache.put(\'template-a.html\',\'<h1 id="template-a">I\\\'m template A!</h1>\');}]);})();' ) ;
397
+ assert . equal ( file . contents . toString ( 'utf8' ) , '(function(){\'use strict\';angular.module(\'templates\').run([\'$templateCache\', function($templateCache) {$templateCache.put(\'/ template-a.html\',\'<h1 id="template-a">I\\\'m template A!</h1>\');}]);})();' ) ;
398
398
cb ( ) ;
399
399
} ) ;
400
400
@@ -420,7 +420,7 @@ describe('gulp-angular-templatecache', function () {
420
420
stream . on ( 'data' , function ( file ) {
421
421
assert . equal ( file . path , path . normalize ( __dirname + '/templates.js' ) ) ;
422
422
assert . equal ( file . relative , 'templates.js' ) ;
423
- assert . equal ( file . contents . toString ( 'utf8' ) , 'var template = "$templateCache.put(\'template-a.html\',\'yoo\');";' ) ;
423
+ assert . equal ( file . contents . toString ( 'utf8' ) , 'var template = "$templateCache.put(\'/ template-a.html\',\'yoo\');";' ) ;
424
424
cb ( ) ;
425
425
} ) ;
426
426
@@ -442,7 +442,7 @@ describe('gulp-angular-templatecache', function () {
442
442
stream . on ( 'data' , function ( file ) { assert
443
443
assert . equal ( file . path , path . normalize ( __dirname + '/templates.js' ) ) ;
444
444
assert . equal ( file . relative , 'templates.js' ) ;
445
- assert . equal ( file . contents . toString ( 'utf8' ) , '$templateCache.put(\'template-a.html\',\'yoo\');' ) ;
445
+ assert . equal ( file . contents . toString ( 'utf8' ) , '$templateCache.put(\'/ template-a.html\',\'yoo\');' ) ;
446
446
cb ( ) ;
447
447
} ) ;
448
448
@@ -466,7 +466,7 @@ describe('gulp-angular-templatecache', function () {
466
466
stream . on ( 'data' , function ( file ) {
467
467
assert . equal ( file . path , path . normalize ( __dirname + '/templates.js' ) ) ;
468
468
assert . equal ( file . relative , 'templates.js' ) ;
469
- assert . equal ( file . contents . toString ( 'utf8' ) , 'angular.module(\'templates\').run([\'$templateCache\', function($templateCache) {$templateCache.put(\'template-a.html\',\'yoo\');}]);' ) ;
469
+ assert . equal ( file . contents . toString ( 'utf8' ) , 'angular.module(\'templates\').run([\'$templateCache\', function($templateCache) {$templateCache.put(\'/ template-a.html\',\'yoo\');}]);' ) ;
470
470
cb ( ) ;
471
471
} ) ;
472
472
0 commit comments