X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=tests%2Fphpunit%2Fincludes%2Fsite%2FSiteTest.php;h=59f046b2ef6530705d33709cacc4179cf96392eb;hb=8956885666e4678a8ff76f7310396d2b2874a858;hp=63d90d2e926c602a58d9b5194a8bd7d8515ada1d;hpb=3368cccde53732c1278f51632e69b9865c4ee6ba;p=lhc%2Fweb%2Fwiklou.git diff --git a/tests/phpunit/includes/site/SiteTest.php b/tests/phpunit/includes/site/SiteTest.php index 63d90d2e92..59f046b2ef 100644 --- a/tests/phpunit/includes/site/SiteTest.php +++ b/tests/phpunit/includes/site/SiteTest.php @@ -228,28 +228,28 @@ class SiteTest extends MediaWikiTestCase { } public static function provideGetPageUrl() { - //NOTE: the assumption that the URL is built by replacing $1 + // NOTE: the assumption that the URL is built by replacing $1 // with the urlencoded version of $page // is true for Site but not guaranteed for subclasses. // Subclasses need to override this provider appropriately. - return array( - array( #0 + return [ + [ # 0 'http://acme.test/TestPath/$1', 'Foo', '/TestPath/Foo', - ), - array( #1 + ], + [ # 1 'http://acme.test/TestScript?x=$1&y=bla', 'Foo', 'TestScript?x=Foo&y=bla', - ), - array( #2 + ], + [ # 2 'http://acme.test/TestPath/$1', 'foo & bar/xyzzy (quux-shmoox?)', '/TestPath/foo%20%26%20bar%2Fxyzzy%20%28quux-shmoox%3F%29', - ), - ); + ], + ]; } /** @@ -259,7 +259,7 @@ class SiteTest extends MediaWikiTestCase { public function testGetPageUrl( $path, $page, $expected ) { $site = new Site(); - //NOTE: the assumption that getPageUrl is based on getLinkPath + // NOTE: the assumption that getPageUrl is based on getLinkPath // is true for Site but not guaranteed for subclasses. // Subclasses need to override this test case appropriately. $site->setLinkPath( $path );