From: Reedy Date: Sat, 11 May 2019 01:17:43 +0000 (+0100) Subject: Remove "Squiz.WhiteSpace.FunctionSpacing" from phpcs exclusions X-Git-Tag: 1.34.0-rc.0~1714^2 X-Git-Url: http://git.cyclocoop.org/%24image?a=commitdiff_plain;h=9f2ffdfbd4c289446f2baf8a168cbe89fa122157;p=lhc%2Fweb%2Fwiklou.git Remove "Squiz.WhiteSpace.FunctionSpacing" from phpcs exclusions Change-Id: I78b3315f26ab91b6b443f5b028a635552f82f5a3 --- diff --git a/.phpcs.xml b/.phpcs.xml index f4567aceea..a9c658a6b8 100644 --- a/.phpcs.xml +++ b/.phpcs.xml @@ -19,7 +19,6 @@ - diff --git a/includes/FormOptions.php b/includes/FormOptions.php index a6e01cc0e8..0131855498 100644 --- a/includes/FormOptions.php +++ b/includes/FormOptions.php @@ -384,6 +384,7 @@ class FormOptions implements ArrayAccess { * @see https://www.php.net/manual/en/class.arrayaccess.php */ /* @{ */ + /** * Whether the option exists. * @param string $name diff --git a/includes/MediaWikiServices.php b/includes/MediaWikiServices.php index 9dbfc1bec7..eca5b9dc78 100644 --- a/includes/MediaWikiServices.php +++ b/includes/MediaWikiServices.php @@ -226,6 +226,7 @@ class MediaWikiServices extends ServiceContainer { } /** @noinspection PhpDocSignatureInspection */ + /** * Salvages the state of any salvageable service instances in $other. * diff --git a/includes/WebStart.php b/includes/WebStart.php index 878dd3eca5..c83fdea511 100644 --- a/includes/WebStart.php +++ b/includes/WebStart.php @@ -50,6 +50,7 @@ if ( !defined( 'MW_CONFIG_CALLBACK' ) ) { define( 'MW_CONFIG_FILE', "$IP/LocalSettings.php" ); } if ( !is_readable( MW_CONFIG_FILE ) ) { + function wfWebStartNoLocalSettings() { # LocalSettings.php is the per-site customization file. If it does not exist # the wiki installer needs to be launched or the generated file uploaded to @@ -58,12 +59,14 @@ if ( !defined( 'MW_CONFIG_CALLBACK' ) ) { require_once "$IP/includes/NoLocalSettings.php"; die(); } + define( 'MW_CONFIG_CALLBACK', 'wfWebStartNoLocalSettings' ); } } // Custom setup for WebStart entry point if ( !defined( 'MW_SETUP_CALLBACK' ) ) { + function wfWebStartSetup() { // Initialise output buffering // Check for previously set up buffers, to avoid a mix of gzip and non-gzip output. @@ -71,6 +74,7 @@ if ( !defined( 'MW_SETUP_CALLBACK' ) ) { ob_start( 'MediaWiki\\OutputHandler::handle' ); } } + define( 'MW_SETUP_CALLBACK', 'wfWebStartSetup' ); } diff --git a/includes/actions/HistoryAction.php b/includes/actions/HistoryAction.php index 658ee48081..706241adcc 100644 --- a/includes/actions/HistoryAction.php +++ b/includes/actions/HistoryAction.php @@ -139,6 +139,7 @@ class HistoryAction extends FormlessAction { } return $year && $month && $day ? $year . '-' . $month . '-' . $day : ''; } + /** * Print the history page for an article. */ diff --git a/includes/exception/MWException.php b/includes/exception/MWException.php index cb7ff19b35..c16d9f7f8f 100644 --- a/includes/exception/MWException.php +++ b/includes/exception/MWException.php @@ -252,6 +252,7 @@ class MWException extends Exception { header( $header ); } } + private static function statusHeader( $code ) { if ( !headers_sent() ) { HttpStatus::header( $code ); diff --git a/includes/libs/objectcache/MultiWriteBagOStuff.php b/includes/libs/objectcache/MultiWriteBagOStuff.php index adb9bb8ae4..1ed91ea298 100644 --- a/includes/libs/objectcache/MultiWriteBagOStuff.php +++ b/includes/libs/objectcache/MultiWriteBagOStuff.php @@ -136,6 +136,7 @@ class MultiWriteBagOStuff extends BagOStuff { return $value; } + public function set( $key, $value, $exptime = 0, $flags = 0 ) { return $this->doWrite( $this->cacheIndexes, @@ -205,6 +206,7 @@ class MultiWriteBagOStuff extends BagOStuff { // Only the first cache is locked return $this->caches[0]->unlock( $key ); } + /** * Delete objects expiring before a certain date. * @@ -289,6 +291,7 @@ class MultiWriteBagOStuff extends BagOStuff { public function clearLastError() { $this->caches[0]->clearLastError(); } + /** * Apply a write method to the backing caches specified by $indexes (in order) * diff --git a/includes/media/Exif.php b/includes/media/Exif.php index 0fde38636b..6dfa8d32e8 100644 --- a/includes/media/Exif.php +++ b/includes/media/Exif.php @@ -548,6 +548,7 @@ class Exif { /**#@+ * @return array */ + /** * Get $this->mRawExifData * @return array diff --git a/includes/pager/Pager.php b/includes/pager/Pager.php index edec490c73..9cfbfbf332 100644 --- a/includes/pager/Pager.php +++ b/includes/pager/Pager.php @@ -31,5 +31,6 @@ */ interface Pager { function getNavigationBar(); + function getBody(); } diff --git a/includes/parser/CoreParserFunctions.php b/includes/parser/CoreParserFunctions.php index 7ce96bebaf..0c745c9f18 100644 --- a/includes/parser/CoreParserFunctions.php +++ b/includes/parser/CoreParserFunctions.php @@ -514,6 +514,7 @@ class CoreParserFunctions { public static function numberofusers( $parser, $raw = null ) { return self::formatRaw( SiteStats::users(), $raw, $parser->getFunctionLang() ); } + public static function numberofactiveusers( $parser, $raw = null ) { return self::formatRaw( SiteStats::activeUsers(), $raw, $parser->getFunctionLang() ); } @@ -545,6 +546,7 @@ class CoreParserFunctions { $parser->getFunctionLang() ); } + public static function numberingroup( $parser, $name = '', $raw = null ) { return self::formatRaw( SiteStats::numberingroup( strtolower( $name ) ), @@ -569,6 +571,7 @@ class CoreParserFunctions { } return str_replace( '_', ' ', $t->getNsText() ); } + public static function namespacee( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) ) { @@ -576,6 +579,7 @@ class CoreParserFunctions { } return wfUrlencode( $t->getNsText() ); } + public static function namespacenumber( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) ) { @@ -583,6 +587,7 @@ class CoreParserFunctions { } return $t->getNamespace(); } + public static function talkspace( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) || !$t->canHaveTalkPage() ) { @@ -590,6 +595,7 @@ class CoreParserFunctions { } return str_replace( '_', ' ', $t->getTalkNsText() ); } + public static function talkspacee( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) || !$t->canHaveTalkPage() ) { @@ -597,6 +603,7 @@ class CoreParserFunctions { } return wfUrlencode( $t->getTalkNsText() ); } + public static function subjectspace( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) ) { @@ -604,6 +611,7 @@ class CoreParserFunctions { } return str_replace( '_', ' ', $t->getSubjectNsText() ); } + public static function subjectspacee( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) ) { @@ -626,6 +634,7 @@ class CoreParserFunctions { } return wfEscapeWikiText( $t->getText() ); } + public static function pagenamee( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) ) { @@ -633,6 +642,7 @@ class CoreParserFunctions { } return wfEscapeWikiText( $t->getPartialURL() ); } + public static function fullpagename( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) || !$t->canHaveTalkPage() ) { @@ -640,6 +650,7 @@ class CoreParserFunctions { } return wfEscapeWikiText( $t->getPrefixedText() ); } + public static function fullpagenamee( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) || !$t->canHaveTalkPage() ) { @@ -647,6 +658,7 @@ class CoreParserFunctions { } return wfEscapeWikiText( $t->getPrefixedURL() ); } + public static function subpagename( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) ) { @@ -654,6 +666,7 @@ class CoreParserFunctions { } return wfEscapeWikiText( $t->getSubpageText() ); } + public static function subpagenamee( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) ) { @@ -661,6 +674,7 @@ class CoreParserFunctions { } return wfEscapeWikiText( $t->getSubpageUrlForm() ); } + public static function rootpagename( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) ) { @@ -668,6 +682,7 @@ class CoreParserFunctions { } return wfEscapeWikiText( $t->getRootText() ); } + public static function rootpagenamee( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) ) { @@ -675,6 +690,7 @@ class CoreParserFunctions { } return wfEscapeWikiText( wfUrlencode( str_replace( ' ', '_', $t->getRootText() ) ) ); } + public static function basepagename( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) ) { @@ -682,6 +698,7 @@ class CoreParserFunctions { } return wfEscapeWikiText( $t->getBaseText() ); } + public static function basepagenamee( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) ) { @@ -689,6 +706,7 @@ class CoreParserFunctions { } return wfEscapeWikiText( wfUrlencode( str_replace( ' ', '_', $t->getBaseText() ) ) ); } + public static function talkpagename( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) || !$t->canHaveTalkPage() ) { @@ -696,6 +714,7 @@ class CoreParserFunctions { } return wfEscapeWikiText( $t->getTalkPage()->getPrefixedText() ); } + public static function talkpagenamee( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) || !$t->canHaveTalkPage() ) { @@ -703,6 +722,7 @@ class CoreParserFunctions { } return wfEscapeWikiText( $t->getTalkPage()->getPrefixedURL() ); } + public static function subjectpagename( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) ) { @@ -710,6 +730,7 @@ class CoreParserFunctions { } return wfEscapeWikiText( $t->getSubjectPage()->getPrefixedText() ); } + public static function subjectpagenamee( $parser, $title = null ) { $t = Title::newFromText( $title ); if ( is_null( $t ) ) { diff --git a/includes/parser/ParserCache.php b/includes/parser/ParserCache.php index 8e8cd98c38..2585872c2f 100644 --- a/includes/parser/ParserCache.php +++ b/includes/parser/ParserCache.php @@ -57,6 +57,7 @@ class ParserCache { * @var string */ private $cacheEpoch; + /** * Get an instance of this object * diff --git a/includes/parser/ParserOutput.php b/includes/parser/ParserOutput.php index cc707134b8..ef22a1f235 100644 --- a/includes/parser/ParserOutput.php +++ b/includes/parser/ParserOutput.php @@ -498,6 +498,7 @@ class ParserOutput extends CacheTime { public function setNoGallery( $value ) { $this->mNoGallery = (bool)$value; } + public function getNoGallery() { return $this->mNoGallery; } @@ -628,12 +629,15 @@ class ParserOutput extends CacheTime { public function setNewSection( $value ) { $this->mNewSection = (bool)$value; } + public function hideNewSection( $value ) { $this->mHideNewSection = (bool)$value; } + public function getHideNewSection() { return (bool)$this->mHideNewSection; } + public function getNewSection() { return (bool)$this->mNewSection; } diff --git a/includes/parser/RemexStripTagHandler.php b/includes/parser/RemexStripTagHandler.php index 2d75c869ec..cb85627e13 100644 --- a/includes/parser/RemexStripTagHandler.php +++ b/includes/parser/RemexStripTagHandler.php @@ -9,6 +9,7 @@ use RemexHtml\Tokenizer\Tokenizer; */ class RemexStripTagHandler implements TokenHandler { private $text = ''; + public function getResult() { return $this->text; } @@ -16,15 +17,19 @@ class RemexStripTagHandler implements TokenHandler { function startDocument( Tokenizer $t, $fns, $fn ) { // Do nothing. } + function endDocument( $pos ) { // Do nothing. } + function error( $text, $pos ) { // Do nothing. } + function characters( $text, $start, $length, $sourceStart, $sourceLength ) { $this->text .= substr( $text, $start, $length ); } + function startTag( $name, Attributes $attrs, $selfClose, $sourceStart, $sourceLength ) { // Inject whitespace for typical block-level tags to // prevent merging unrelated
words. @@ -32,6 +37,7 @@ class RemexStripTagHandler implements TokenHandler { $this->text .= ' '; } } + function endTag( $name, $sourceStart, $sourceLength ) { // Inject whitespace for typical block-level tags to // prevent merging unrelated
words. @@ -39,9 +45,11 @@ class RemexStripTagHandler implements TokenHandler { $this->text .= ' '; } } + function doctype( $name, $public, $system, $quirks, $sourceStart, $sourceLength ) { // Do nothing. } + function comment( $text, $sourceStart, $sourceLength ) { // Do nothing. } diff --git a/includes/specialpage/ChangesListSpecialPage.php b/includes/specialpage/ChangesListSpecialPage.php index f4b574be46..2470b41419 100644 --- a/includes/specialpage/ChangesListSpecialPage.php +++ b/includes/specialpage/ChangesListSpecialPage.php @@ -1190,6 +1190,7 @@ abstract class ChangesListSpecialPage extends SpecialPage { // to include data on filters that use the unstructured UI. messageKeys is a // special top-level value, with the value being an array of the message keys to // send to the client. + /** * Gets structured filter information needed by JS * diff --git a/includes/specialpage/SpecialPage.php b/includes/specialpage/SpecialPage.php index bd0e24f2e1..670a0b8c98 100644 --- a/includes/specialpage/SpecialPage.php +++ b/includes/specialpage/SpecialPage.php @@ -162,6 +162,7 @@ class SpecialPage implements MessageLocalizer { } // @todo FIXME: Decide which syntax to use for this, and stick to it + /** * Whether this special page is listed in Special:SpecialPages * @since 1.3 (r3583) diff --git a/includes/upload/exception/UploadChunkVerificationException.php b/includes/upload/exception/UploadChunkVerificationException.php index cee8c030d6..d7733abd4e 100644 --- a/includes/upload/exception/UploadChunkVerificationException.php +++ b/includes/upload/exception/UploadChunkVerificationException.php @@ -23,6 +23,7 @@ class UploadChunkVerificationException extends MWException { public $msg; + public function __construct( array $res ) { $this->msg = wfMessage( ...$res ); parent::__construct( wfMessage( ...$res ) diff --git a/maintenance/doMaintenance.php b/maintenance/doMaintenance.php index 1c53fe8400..94ae95d73d 100644 --- a/maintenance/doMaintenance.php +++ b/maintenance/doMaintenance.php @@ -61,6 +61,7 @@ if ( !defined( 'MW_CONFIG_CALLBACK' ) && !defined( 'MW_CONFIG_FILE' ) ) { // Custom setup for Maintenance entry point if ( !defined( 'MW_SETUP_CALLBACK' ) ) { + function wfMaintenanceSetup() { // phpcs:ignore MediaWiki.NamingConventions.ValidGlobalName.wgPrefix global $maintenance, $wgLocalisationCacheConf, $wgCacheDirectory; @@ -75,6 +76,7 @@ if ( !defined( 'MW_SETUP_CALLBACK' ) ) { $maintenance->finalSetup(); } + define( 'MW_SETUP_CALLBACK', 'wfMaintenanceSetup' ); } diff --git a/maintenance/removeInvalidEmails.php b/maintenance/removeInvalidEmails.php index ec68ef2e77..bee8d693a8 100644 --- a/maintenance/removeInvalidEmails.php +++ b/maintenance/removeInvalidEmails.php @@ -21,6 +21,7 @@ class RemoveInvalidEmails extends Maintenance { $this->addOption( 'commit', 'Whether to actually update the database', false, false ); $this->setBatchSize( 500 ); } + public function execute() { $this->commit = $this->hasOption( 'commit' ); $dbr = $this->getDB( DB_REPLICA ); diff --git a/maintenance/validateRegistrationFile.php b/maintenance/validateRegistrationFile.php index 0d6cfa2412..a704d61a93 100644 --- a/maintenance/validateRegistrationFile.php +++ b/maintenance/validateRegistrationFile.php @@ -11,6 +11,7 @@ class ValidateRegistrationFile extends Maintenance { true ); } + public function execute() { $validator = new ExtensionJsonValidator( function ( $msg ) { $this->fatalError( $msg ); diff --git a/tests/phan/bin/postprocess-phan.php b/tests/phan/bin/postprocess-phan.php index 3e80598677..4f48f4896e 100644 --- a/tests/phan/bin/postprocess-phan.php +++ b/tests/phan/bin/postprocess-phan.php @@ -106,6 +106,7 @@ class NoopSuppressor extends Suppressor { public function __construct( $mode ) { $this->mode = $mode; } + public function suppress( $input ) { echo "Unsupported output mode: {$this->mode}\n$input"; return true; diff --git a/tests/phpunit/ResourceLoaderTestCase.php b/tests/phpunit/ResourceLoaderTestCase.php index 57f56f4400..e9a8a1fa3c 100644 --- a/tests/phpunit/ResourceLoaderTestCase.php +++ b/tests/phpunit/ResourceLoaderTestCase.php @@ -137,6 +137,7 @@ class ResourceLoaderTestModule extends ResourceLoaderModule { public function isRaw() { return $this->isRaw; } + public function isKnownEmpty( ResourceLoaderContext $context ) { return $this->isKnownEmpty; } diff --git a/tests/phpunit/includes/FormOptionsTest.php b/tests/phpunit/includes/FormOptionsTest.php index 2ee8b9833b..da08670f57 100644 --- a/tests/phpunit/includes/FormOptionsTest.php +++ b/tests/phpunit/includes/FormOptionsTest.php @@ -42,15 +42,19 @@ class FormOptionsTest extends MediaWikiTestCase { private function assertGuessBoolean( $data ) { $this->guess( FormOptions::BOOL, $data ); } + private function assertGuessInt( $data ) { $this->guess( FormOptions::INT, $data ); } + private function assertGuessFloat( $data ) { $this->guess( FormOptions::FLOAT, $data ); } + private function assertGuessString( $data ) { $this->guess( FormOptions::STRING, $data ); } + private function assertGuessArray( $data ) { $this->guess( FormOptions::ARR, $data ); } @@ -62,6 +66,7 @@ class FormOptionsTest extends MediaWikiTestCase { FormOptions::guessType( $data ) ); } + /* @} */ /** diff --git a/tests/phpunit/includes/OutputPageTest.php b/tests/phpunit/includes/OutputPageTest.php index ef8766a966..afc6bb582d 100644 --- a/tests/phpunit/includes/OutputPageTest.php +++ b/tests/phpunit/includes/OutputPageTest.php @@ -25,6 +25,7 @@ class OutputPageTest extends MediaWikiTestCase { parent::setUp(); ResourceLoader::clearCache(); } + protected function tearDown() { parent::tearDown(); ResourceLoader::clearCache(); diff --git a/tests/phpunit/includes/content/JsonContentTest.php b/tests/phpunit/includes/content/JsonContentTest.php index 8546d967a6..8d6c3aecf3 100644 --- a/tests/phpunit/includes/content/JsonContentTest.php +++ b/tests/phpunit/includes/content/JsonContentTest.php @@ -92,6 +92,7 @@ class JsonContentTest extends MediaWikiLangTestCase { ->disableOriginalConstructor() ->getMock(); } + private function getMockParserOptions() { return $this->getMockBuilder( ParserOptions::class ) ->disableOriginalConstructor() diff --git a/tests/phpunit/includes/resourceloader/ResourceLoaderImageTest.php b/tests/phpunit/includes/resourceloader/ResourceLoaderImageTest.php index 35c3ef6454..b0512faac6 100644 --- a/tests/phpunit/includes/resourceloader/ResourceLoaderImageTest.php +++ b/tests/phpunit/includes/resourceloader/ResourceLoaderImageTest.php @@ -129,6 +129,7 @@ class ResourceLoaderImageTestable extends ResourceLoaderImage { public function massageSvgPathdata( $svg ) { return parent::massageSvgPathdata( $svg ); } + // Stub, since we don't know if we even have a SVG handler, much less what exactly it'll output public function rasterize( $svg ) { return 'RASTERIZESTUB'; diff --git a/tests/phpunit/includes/resourceloader/ResourceLoaderWikiModuleTest.php b/tests/phpunit/includes/resourceloader/ResourceLoaderWikiModuleTest.php index ad8fa78c7a..c1bdebec66 100644 --- a/tests/phpunit/includes/resourceloader/ResourceLoaderWikiModuleTest.php +++ b/tests/phpunit/includes/resourceloader/ResourceLoaderWikiModuleTest.php @@ -451,6 +451,7 @@ class ResourceLoaderWikiModuleTest extends ResourceLoaderTestCase { class TestResourceLoaderWikiModule extends ResourceLoaderWikiModule { public static $returnFetchTitleInfo = null; + protected static function fetchTitleInfo( IDatabase $db, array $pages, $fname = null ) { $ret = self::$returnFetchTitleInfo; self::$returnFetchTitleInfo = null; diff --git a/tests/phpunit/includes/specialpage/ChangesListSpecialPageTest.php b/tests/phpunit/includes/specialpage/ChangesListSpecialPageTest.php index f54594857e..968db42816 100644 --- a/tests/phpunit/includes/specialpage/ChangesListSpecialPageTest.php +++ b/tests/phpunit/includes/specialpage/ChangesListSpecialPageTest.php @@ -400,6 +400,7 @@ class ChangesListSpecialPageTest extends AbstractChangesListSpecialPageTestCase $user ); } + public function testRcHidepatrolledFilter() { $user = $this->getTestSysop()->getUser(); $this->assertConditions( diff --git a/tests/phpunit/includes/title/NamespaceInfoTest.php b/tests/phpunit/includes/title/NamespaceInfoTest.php index 556c640bd6..4e376e8051 100644 --- a/tests/phpunit/includes/title/NamespaceInfoTest.php +++ b/tests/phpunit/includes/title/NamespaceInfoTest.php @@ -601,6 +601,7 @@ class NamespaceInfoTest extends MediaWikiTestCase { * getSubject/Talk/Associated * %{ */ + /** * @dataProvider provideSubjectTalk * @covers NamespaceInfo::getSubject @@ -880,6 +881,7 @@ class NamespaceInfoTest extends MediaWikiTestCase { // No canonical namespace names // %{ + /** * @covers NamespaceInfo::getCanonicalNamespaces */ @@ -982,6 +984,7 @@ class NamespaceInfoTest extends MediaWikiTestCase { // Hook namespaces // %{ + /** * @return array Expected canonical namespaces */ @@ -1047,6 +1050,7 @@ class NamespaceInfoTest extends MediaWikiTestCase { // Extra namespaces // %{ + /** * @return NamespaceInfo */ @@ -1102,6 +1106,7 @@ class NamespaceInfoTest extends MediaWikiTestCase { // Canonical namespace caching // %{ + /** * @covers NamespaceInfo::getCanonicalNamespaces */ diff --git a/tests/phpunit/languages/classes/LanguageSrTest.php b/tests/phpunit/languages/classes/LanguageSrTest.php index c9f2f3edf7..8da760237a 100644 --- a/tests/phpunit/languages/classes/LanguageSrTest.php +++ b/tests/phpunit/languages/classes/LanguageSrTest.php @@ -238,6 +238,7 @@ class LanguageSrTest extends LanguageClassesTestCase { } # #### HELPERS ##################################################### + /** *Wrapper to verify text stay the same after applying conversion * @param string $text Text to convert diff --git a/tests/phpunit/languages/classes/LanguageUzTest.php b/tests/phpunit/languages/classes/LanguageUzTest.php index 18b2031f80..abc63ee4e3 100644 --- a/tests/phpunit/languages/classes/LanguageUzTest.php +++ b/tests/phpunit/languages/classes/LanguageUzTest.php @@ -60,6 +60,7 @@ class LanguageUzTest extends LanguageClassesTestCase { } # #### HELPERS ##################################################### + /** * Wrapper to verify text stay the same after applying conversion * @param string $text Text to convert diff --git a/tests/phpunit/mocks/search/MockSearchResult.php b/tests/phpunit/mocks/search/MockSearchResult.php index d92d39a634..e92eb5660c 100644 --- a/tests/phpunit/mocks/search/MockSearchResult.php +++ b/tests/phpunit/mocks/search/MockSearchResult.php @@ -7,6 +7,7 @@ class MockSearchResult extends SearchResult { public function isMissingRevision() { return $this->isMissingRevision; } + public function setMissingRevision( $isMissingRevision ) { $this->isMissingRevision = $isMissingRevision; return $this;