Drop 'comma' value for wgArticleCountMethod
[lhc/web/wiklou.git] / tests / phpunit / includes / content / JavaScriptContentTest.php
index 8cbbfb8..823be6f 100644 (file)
@@ -141,26 +141,6 @@ class JavaScriptContentTest extends TextContentTest {
                ];
        }
 
-       /**
-        * @todo Test needs database!
-        */
-       /*
-       public function getRedirectChain() {
-               $text = $this->getNativeData();
-               return Title::newFromRedirectArray( $text );
-       }
-       */
-
-       /**
-        * @todo Test needs database!
-        */
-       /*
-       public function getUltimateRedirectTarget() {
-               $text = $this->getNativeData();
-               return Title::newFromRedirectRecurse( $text );
-       }
-       */
-
        public static function dataIsCountable() {
                return [
                        [ '',
@@ -173,16 +153,6 @@ class JavaScriptContentTest extends TextContentTest {
                                'any',
                                true
                        ],
-                       [ 'Foo',
-                               null,
-                               'comma',
-                               false
-                       ],
-                       [ 'Foo, bar',
-                               null,
-                               'comma',
-                               false
-                       ],
                        [ 'Foo',
                                null,
                                'link',
@@ -208,11 +178,6 @@ class JavaScriptContentTest extends TextContentTest {
                                'any',
                                true
                        ],
-                       [ '#REDIRECT [[bar]]',
-                               true,
-                               'comma',
-                               false
-                       ],
                        [ '#REDIRECT [[bar]]',
                                true,
                                'link',
@@ -271,19 +236,18 @@ class JavaScriptContentTest extends TextContentTest {
        }
 
        public static function provideUpdateRedirect() {
+               // phpcs:disable Generic.Files.LineLength
                return [
                        [
                                '#REDIRECT [[Someplace]]',
                                '#REDIRECT [[Someplace]]',
                        ],
-
-                       // @codingStandardsIgnoreStart Generic.Files.LineLength
                        [
                                '/* #REDIRECT */mw.loader.load("//example.org/w/index.php?title=MediaWiki:MonoBook.js\u0026action=raw\u0026ctype=text/javascript");',
                                '/* #REDIRECT */mw.loader.load("//example.org/w/index.php?title=TestUpdateRedirect_target\u0026action=raw\u0026ctype=text/javascript");'
                        ]
-                       // @codingStandardsIgnoreEnd
                ];
+               // phpcs:enable
        }
 
        /**
@@ -314,6 +278,7 @@ class JavaScriptContentTest extends TextContentTest {
        }
 
        /**
+        * @covers JavaScriptContent::getRedirectTarget
         * @dataProvider provideGetRedirectTarget
         */
        public function testGetRedirectTarget( $title, $text ) {
@@ -332,7 +297,7 @@ class JavaScriptContentTest extends TextContentTest {
         * Keep this in sync with JavaScriptContentHandlerTest::provideMakeRedirectContent()
         */
        public static function provideGetRedirectTarget() {
-               // @codingStandardsIgnoreStart Generic.Files.LineLength
+               // phpcs:disable Generic.Files.LineLength
                return [
                        [
                                'MediaWiki:MonoBook.js',
@@ -357,6 +322,6 @@ class JavaScriptContentTest extends TextContentTest {
                                '/* #REDIRECT */mw.loader.load("//example.com/w/index.php?title=MediaWiki:OtherWiki.js\u0026action=raw\u0026ctype=text/javascript");'
                        ],
                ];
-               // @codingStandardsIgnoreEnd
+               // phpcs:enable
        }
 }