X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=tests%2Fphpunit%2Fincludes%2Fcontent%2FJavaScriptContentTest.php;h=a4dd1fceb07ed19acbb6e5d318303d3a43d19786;hb=9eafd89011b9b031d902a4381e13254fb67e1e07;hp=9506c364c5dfa3527edc04caf6cb48286fa55439;hpb=b79bc0a2740b991525aae355ed216e0b9dc3aa86;p=lhc%2Fweb%2Fwiklou.git diff --git a/tests/phpunit/includes/content/JavaScriptContentTest.php b/tests/phpunit/includes/content/JavaScriptContentTest.php index 9506c364c5..a4dd1fceb0 100644 --- a/tests/phpunit/includes/content/JavaScriptContentTest.php +++ b/tests/phpunit/includes/content/JavaScriptContentTest.php @@ -234,7 +234,7 @@ class JavaScriptContentTest extends TextContentTest { $content = new JavaScriptContent( $oldText ); $newContent = $content->updateRedirect( $target ); - $this->assertEquals( $expectedText, $newContent->getNativeData() ); + $this->assertEquals( $expectedText, $newContent->getText() ); } public static function provideUpdateRedirect() { @@ -313,6 +313,11 @@ class JavaScriptContentTest extends TextContentTest { 'Gadget:FooBaz.js', '/* #REDIRECT */mw.loader.load("//example.org/w/index.php?title=Gadget:FooBaz.js\u0026action=raw\u0026ctype=text/javascript");' ], + // Unicode + [ + 'User:😂/unicode.js', + '/* #REDIRECT */mw.loader.load("//example.org/w/index.php?title=User:%F0%9F%98%82/unicode.js\u0026action=raw\u0026ctype=text/javascript");' + ], // No #REDIRECT comment [ null,