@@ -1246,7 +1246,7 @@ QUnit.test( "pseudo - :target and :root", function( assert ) {
1246
1246
} ) ;
1247
1247
1248
1248
QUnit . test ( "pseudo - :lang" , function ( assert ) {
1249
- assert . expect ( 105 ) ;
1249
+ assert . expect ( 104 ) ;
1250
1250
1251
1251
var docElem = document . documentElement ,
1252
1252
docXmlLang = docElem . getAttribute ( "xml:lang" ) ,
@@ -1319,8 +1319,17 @@ QUnit.test( "pseudo - :lang", function( assert ) {
1319
1319
anchor . parentNode . lang = "ara" ;
1320
1320
anchor . lang = "ara\\b" ;
1321
1321
assert . deepEqual ( Sizzle ( ":lang(ara\\b)" , foo ) , [ ] , ":lang respects backslashes" ) ;
1322
- assert . deepEqual ( Sizzle ( ":lang(ara\\\\b)" , foo ) , [ anchor ] ,
1323
- ":lang respects escaped backslashes" ) ;
1322
+
1323
+ // Support: Firefox 114+
1324
+ // Firefox 114+ no longer match on backslashes in `:lang()`, even when escaped.
1325
+ // It is an intentional change as `:lang()` parameters are supposed to be valid
1326
+ // BCP 47 strings. Therefore, we won't attempt to patch it.
1327
+ // We'll keep this test here until other browsers match the behavior.
1328
+ // See https://bugzilla.mozilla.org/show_bug.cgi?id=1839747#c1
1329
+ // See https://github.com/w3c/csswg-drafts/issues/8720#issuecomment-1509242961
1330
+ // assert.deepEqual( Sizzle( ":lang(ara\\\\b)", foo ), [ anchor ],
1331
+ // ":lang respects escaped backslashes" );
1332
+
1324
1333
assert . throws ( function ( ) {
1325
1334
Sizzle . call ( null , "#qunit-fixture:lang(c++)" ) ;
1326
1335
} , function ( e ) {
0 commit comments