@@ -27,7 +27,7 @@ describe('template', () => {
27
27
28
28
const results = inlineTemplate ( sourceText , join ( baseDir , 'some-file.ts' ) ) ;
29
29
30
- expect ( results ) . toEqual ( `/*someprefix*/@Component({template:/*ion-inline-start:"${ join ( baseDir , 'some-file.html' ) } "*/' <div>A</div>' /*ion-inline-end:"${ join ( baseDir , 'some-file.html' ) } "*/ });/*somebetween*/@Component({template:/*ion-inline-start:"${ join ( baseDir , 'some-file.html' ) } "*/' <div>A</div>' /*ion-inline-end:"${ join ( baseDir , 'some-file.html' ) } "*/ })/*somesuffix*/` ) ;
30
+ expect ( results ) . toEqual ( `/*someprefix*/@Component({template:/*ion-inline-start:"${ join ( baseDir , 'some-file.html' ) } "*/\` <div>A</div>\` /*ion-inline-end:"${ join ( baseDir , 'some-file.html' ) } "*/ });/*somebetween*/@Component({template:/*ion-inline-start:"${ join ( baseDir , 'some-file.html' ) } "*/\` <div>A</div>\` /*ion-inline-end:"${ join ( baseDir , 'some-file.html' ) } "*/ })/*somesuffix*/` ) ;
31
31
mockFs . restore ( ) ;
32
32
} ) ;
33
33
@@ -47,7 +47,7 @@ describe('template', () => {
47
47
48
48
const results = inlineTemplate ( sourceText , join ( baseDir , 'some-file.ts' ) ) ;
49
49
50
- expect ( results ) . toEqual ( `/*someprefix*/@Component({template:/*ion-inline-start:"${ join ( baseDir , 'some-file1.html' ) } "*/' <div>A</div>' /*ion-inline-end:"${ join ( baseDir , 'some-file1.html' ) } "*/ });/*somebetween*/@Component({template:/*ion-inline-start:"${ join ( baseDir , 'some-file2.html' ) } "*/' <div>B</div>' /*ion-inline-end:"${ join ( baseDir , 'some-file2.html' ) } "*/ })/*somesuffix*/` ) ;
50
+ expect ( results ) . toEqual ( `/*someprefix*/@Component({template:/*ion-inline-start:"${ join ( baseDir , 'some-file1.html' ) } "*/\` <div>A</div>\` /*ion-inline-end:"${ join ( baseDir , 'some-file1.html' ) } "*/ });/*somebetween*/@Component({template:/*ion-inline-start:"${ join ( baseDir , 'some-file2.html' ) } "*/\` <div>B</div>\` /*ion-inline-end:"${ join ( baseDir , 'some-file2.html' ) } "*/ })/*somesuffix*/` ) ;
51
51
mockFs . restore ( ) ;
52
52
} ) ;
53
53
@@ -67,7 +67,7 @@ describe('template', () => {
67
67
68
68
const results = inlineTemplate ( sourceText , join ( baseDir , 'some-file.ts' ) ) ;
69
69
70
- expect ( results ) . toEqual ( `@Component({template:/*ion-inline-start:"${ join ( baseDir , 'some-file.html' ) } "*/' <div>hello</div>' /*ion-inline-end:"${ join ( baseDir , 'some-file.html' ) } "*/ })` ) ;
70
+ expect ( results ) . toEqual ( `@Component({template:/*ion-inline-start:"${ join ( baseDir , 'some-file.html' ) } "*/\` <div>hello</div>\` /*ion-inline-end:"${ join ( baseDir , 'some-file.html' ) } "*/ })` ) ;
71
71
mockFs . restore ( ) ;
72
72
} ) ;
73
73
@@ -149,7 +149,7 @@ describe('template', () => {
149
149
const match = getTemplateMatch ( str ) ;
150
150
const result = replaceTemplateUrl ( match , htmlFilePath , templateContent ) ;
151
151
152
- const expected = `Component({template:/*ion-inline-start:"${ join ( process . cwd ( ) , 'full' , 'path' , 'to' , 'somepage.html' ) } "*/'\\ n <div>\t\\n this is "multiline" \\'content\\'\\n </div>\\n\\n ' /*ion-inline-end:"${ join ( process . cwd ( ) , 'full' , 'path' , 'to' , 'somepage.html' ) } "*/})` ;
152
+ const expected = `Component({template:/*ion-inline-start:"${ join ( process . cwd ( ) , 'full' , 'path' , 'to' , 'somepage.html' ) } "*/\`\\ n <div>\t\\n this is "multiline" \\'content\\'\\n </div>\\n\\n \` /*ion-inline-end:"${ join ( process . cwd ( ) , 'full' , 'path' , 'to' , 'somepage.html' ) } "*/})` ;
153
153
154
154
expect ( result ) . toEqual ( expected ) ;
155
155
} ) ;
@@ -163,7 +163,7 @@ describe('template', () => {
163
163
const resolvedPath = resolve ( path ) ;
164
164
const results = getTemplateFormat ( path , 'filibuster' ) ;
165
165
expect ( path ) . not . toEqual ( resolvedPath ) ;
166
- expect ( results ) . toEqual ( `template:/*ion-inline-start:"${ resolvedPath } "*/' filibuster' /*ion-inline-end:"${ resolvedPath } "*/` ) ;
166
+ expect ( results ) . toEqual ( `template:/*ion-inline-start:"${ resolvedPath } "*/\` filibuster\` /*ion-inline-end:"${ resolvedPath } "*/` ) ;
167
167
} ) ;
168
168
169
169
} ) ;
0 commit comments