@@ -583,11 +583,13 @@ export default testSuite(({ describe }) => {
583583 style : {
584584 plain : expect . stringMatching ( / _ p l a i n _ \w + / ) ,
585585 composed : expect . stringMatching ( / _ c o m p o s e d _ \w + _ p l a i n _ \w + / ) ,
586+ nested : expect . stringMatching ( / _ n e s t e d _ \w + _ e x t r a _ \w + _ b a s e _ \w + / ) ,
586587 } ,
587588 } ) ;
588589 const dts = await fixture . readFile ( 'style.module.css.d.ts' , 'utf8' ) ;
589590 expect ( dts ) . toMatch ( 'const plain: string;' ) ;
590591 expect ( dts ) . toMatch ( 'const composed: string;' ) ;
592+ expect ( dts ) . toMatch ( 'const nested: string;' ) ;
591593 } ) ;
592594
593595 test ( 'array' , async ( ) => {
@@ -607,11 +609,13 @@ export default testSuite(({ describe }) => {
607609 style : {
608610 plain : expect . stringMatching ( / _ p l a i n _ \w + / ) ,
609611 composed : [ expect . stringMatching ( / _ c o m p o s e d _ \w + / ) , expect . stringMatching ( / _ p l a i n _ \w + / ) ] ,
612+ nested : [ expect . stringMatching ( / _ n e s t e d _ \w + / ) , expect . stringMatching ( / _ e x t r a _ \w + / ) , expect . stringMatching ( / _ b a s e _ \w + / ) ] ,
610613 } ,
611614 } ) ;
612615 const dts = await fixture . readFile ( 'style.module.css.d.ts' , 'utf8' ) ;
613616 expect ( dts ) . toMatch ( 'const plain: string;' ) ;
614617 expect ( dts ) . toMatch ( 'const composed: string[];' ) ;
618+ expect ( dts ) . toMatch ( 'const nested: string[];' ) ;
615619 } ) ;
616620
617621 test ( 'all-array' , async ( ) => {
@@ -631,11 +635,13 @@ export default testSuite(({ describe }) => {
631635 style : {
632636 plain : [ expect . stringMatching ( / _ p l a i n _ \w + / ) ] ,
633637 composed : [ expect . stringMatching ( / _ c o m p o s e d _ \w + / ) , expect . stringMatching ( / _ p l a i n _ \w + / ) ] ,
638+ nested : [ expect . stringMatching ( / _ n e s t e d _ \w + / ) , expect . stringMatching ( / _ e x t r a _ \w + / ) , expect . stringMatching ( / _ b a s e _ \w + / ) ] ,
634639 } ,
635640 } ) ;
636641 const dts = await fixture . readFile ( 'style.module.css.d.ts' , 'utf8' ) ;
637642 expect ( dts ) . toMatch ( 'const plain: string[];' ) ;
638643 expect ( dts ) . toMatch ( 'const composed: string[];' ) ;
644+ expect ( dts ) . toMatch ( 'const nested: string[];' ) ;
639645 } ) ;
640646 } ) ;
641647
0 commit comments