File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed
Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -2052,6 +2052,20 @@ describe('Selector Nodes', () => {
20522052 expect ( lang1 . type ) . toBe ( LANG_SELECTOR )
20532053 expect ( lang1 . text ) . toBe ( '"*-Latn"' )
20542054 } )
2055+
2056+ test ( ':lang(\\*-Latn) with escaped wildcard' , ( ) => {
2057+ const root = parse_selector ( ':lang(\\*-Latn)' )
2058+
2059+ const selector = root . first_child ! as Selector
2060+ const langPseudoClass = selector . first_child ! as PseudoClassSelector
2061+ expect ( langPseudoClass . type ) . toBe ( PSEUDO_CLASS_SELECTOR )
2062+ expect ( langPseudoClass . text ) . toBe ( ':lang(\\*-Latn)' )
2063+ expect ( langPseudoClass . child_count ) . toBe ( 1 )
2064+
2065+ const lang1 = langPseudoClass . first_child !
2066+ expect ( lang1 . type ) . toBe ( LANG_SELECTOR )
2067+ expect ( lang1 . text ) . toBe ( '\\*-Latn' )
2068+ } )
20552069 } )
20562070
20572071 describe ( ':is() and :where() pseudo-classes' , ( ) => {
You can’t perform that action at this time.
0 commit comments