diff --git a/.phpcs.xml b/.phpcs.xml index e0e39d6f2..87dd9e63b 100644 --- a/.phpcs.xml +++ b/.phpcs.xml @@ -2,8 +2,11 @@ + + + . diff --git a/composer.json b/composer.json index 8c617fa05..f10026ad8 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "require-dev": { "jakub-onderka/php-parallel-lint": "1.0.0", - "mediawiki/mediawiki-codesniffer": "24.0.0", + "mediawiki/mediawiki-codesniffer": "28.0.0", "jakub-onderka/php-console-highlighter": "0.3.2", "mediawiki/minus-x": "0.3.1", "mediawiki/mediawiki-phan-config": "0.6.1" diff --git a/includes/menu/Main/MainMenuDirector.php b/includes/menu/Main/MainMenuDirector.php index 214bbc99c..f0d973e1a 100644 --- a/includes/menu/Main/MainMenuDirector.php +++ b/includes/menu/Main/MainMenuDirector.php @@ -23,7 +23,7 @@ use Html; use MessageLocalizer; use MinervaUI; use SpecialPage; -use \MediaWiki\Special\SpecialPageFactory; +use MediaWiki\Special\SpecialPageFactory; /** * Director responsible for building Main Menu diff --git a/includes/menu/PageActions/ToolbarBuilder.php b/includes/menu/PageActions/ToolbarBuilder.php index 584c9cdc4..60dbf75a1 100644 --- a/includes/menu/PageActions/ToolbarBuilder.php +++ b/includes/menu/PageActions/ToolbarBuilder.php @@ -71,6 +71,7 @@ class ToolbarBuilder { * @var LanguagesHelper */ private $languagesHelper; + /** * Build Group containing icons for toolbar * @param Title $title Article title user is currently browsing diff --git a/includes/skins/SkinMinerva.php b/includes/skins/SkinMinerva.php index 6af53167f..339c485b7 100644 --- a/includes/skins/SkinMinerva.php +++ b/includes/skins/SkinMinerva.php @@ -333,6 +333,7 @@ class SkinMinerva extends SkinTemplate { $tpl->set( 'userNotificationsHTML', $badge ); } } + /** * Rewrites the language list so that it cannot be contaminated by other extensions with things * other than languages @@ -481,6 +482,7 @@ class SkinMinerva extends SkinTemplate { $attrs[ 'class' ] = 'tagline'; return Html::element( 'div', $attrs, $tagline ); } + /** * Returns the HTML representing the heading. * @return string HTML for header diff --git a/tests/phpunit/skins/SkinMinervaTest.php b/tests/phpunit/skins/SkinMinervaTest.php index 7ea683d74..e2d3dbfe7 100644 --- a/tests/phpunit/skins/SkinMinervaTest.php +++ b/tests/phpunit/skins/SkinMinervaTest.php @@ -19,12 +19,15 @@ class EchoNotifUser { $this->lastUnreadMessageTime = $lastUnreadMessageTime; $this->echoNotificationCount = $echoNotificationCount; } + public function getLastUnreadAlertTime() { return $this->lastUnreadAlertTime; } + public function getLastUnreadMessageTime() { return $this->lastUnreadMessageTime; } + public function getNotificationCount() { return $this->echoNotificationCount; }