@@ -241,17 +241,17 @@ describe('production', () => {
241241 const main = await fs . readFile ( path . join ( env . tmp . path , 'dist' , roots [ 2 ] ) , 'utf8' ) ;
242242
243243 // https://cdn.example.com/assets/math.d41e7373.css
244- expect ( math . includes ( `("https://cdn.example.com/assets/${ assets [ 1 ] } ")` ) ) . toBe ( true ) ;
245- expect ( math . includes ( `import("./${ chunks [ 0 ] } ")` ) ) . toBe ( true ) ;
244+ expect ( math ) . toMatch ( `("https://cdn.example.com/assets/${ assets [ 1 ] } ")` ) ;
245+ expect ( math ) . toMatch ( `import("./${ chunks [ 0 ] } ")` ) ;
246246
247247 // (preload) https://cdn.example.com/assets/math.d41e7373.css
248- expect ( main . includes ( `$w_s$("https://cdn.example.com/assets/${ assets [ 1 ] } ")` ) ) . toBe ( true ) ;
248+ expect ( main ) . toMatch ( `$w_s$("https://cdn.example.com/assets/${ assets [ 1 ] } ")` ) ;
249249
250250 // HTML stylesheet: https://cdn.example.com/assets/index.0544f0a6.css
251- expect ( html . includes ( `href="https://cdn.example.com/assets/${ assets [ 0 ] } "` ) ) . toBe ( true ) ;
251+ expect ( html ) . toMatch ( `href="https://cdn.example.com/assets/${ assets [ 0 ] } "` ) ;
252252
253253 // HTML script: https://cdn.example.com/assets/index.0544f0a6.css
254- expect ( html . includes ( `src="https://cdn.example.com/${ roots [ 2 ] } "` ) ) . toBe ( true ) ;
254+ expect ( html ) . toMatch ( `src="https://cdn.example.com/${ roots [ 2 ] } "` ) ;
255255 } ) ;
256256
257257 it ( 'should respect `config.publicPath` value (ts)' , async ( ) => {
@@ -278,17 +278,17 @@ describe('production', () => {
278278 const main = await fs . readFile ( path . join ( env . tmp . path , 'dist' , roots [ 2 ] ) , 'utf8' ) ;
279279
280280 // https://cdn.example.com/assets/math.d41e7373.css
281- expect ( math . includes ( `("https://cdn.example.com/assets/${ assets [ 1 ] } ")` ) ) . toBe ( true ) ;
282- expect ( math . includes ( `import("./${ chunks [ 0 ] } ")` ) ) . toBe ( true ) ;
281+ expect ( math ) . toMatch ( `("https://cdn.example.com/assets/${ assets [ 1 ] } ")` ) ;
282+ expect ( math ) . toMatch ( `import("./${ chunks [ 0 ] } ")` ) ;
283283
284284 // (preload) https://cdn.example.com/assets/math.d41e7373.css
285- expect ( main . includes ( `$w_s$("https://cdn.example.com/assets/${ assets [ 1 ] } ")` ) ) . toBe ( true ) ;
285+ expect ( main ) . toMatch ( `$w_s$("https://cdn.example.com/assets/${ assets [ 1 ] } ")` ) ;
286286
287287 // HTML stylesheet: https://cdn.example.com/assets/index.0544f0a6.css
288- expect ( html . includes ( `href="https://cdn.example.com/assets/${ assets [ 0 ] } "` ) ) . toBe ( true ) ;
288+ expect ( html ) . toMatch ( `href="https://cdn.example.com/assets/${ assets [ 0 ] } "` ) ;
289289
290290 // HTML script: https://cdn.example.com/assets/index.0544f0a6.css
291- expect ( html . includes ( `src="https://cdn.example.com/${ roots [ 2 ] } "` ) ) . toBe ( true ) ;
291+ expect ( html ) . toMatch ( `src="https://cdn.example.com/${ roots [ 2 ] } "` ) ;
292292 } ) ;
293293 } ) ;
294294
0 commit comments