mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/SpamBlacklist
synced 2024-11-14 10:54:40 +00:00
Use MediaWikiServices::getMessageCache
This required MediaWiki 1.34 Change-Id: I86291dfaf83cdeeb96693979272bf7d4589d650f
This commit is contained in:
parent
f28db2b7c8
commit
1cdb1d25c8
|
@ -10,7 +10,7 @@
|
|||
"type": "antispam",
|
||||
"license-name": "GPL-2.0-or-later",
|
||||
"requires": {
|
||||
"MediaWiki": ">= 1.31.0"
|
||||
"MediaWiki": ">= 1.34.0"
|
||||
},
|
||||
"GroupPermissions": {
|
||||
"user": {
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
<?php
|
||||
|
||||
use MediaWiki\MediaWikiServices;
|
||||
|
||||
/**
|
||||
* @group SpamBlacklist
|
||||
* @group Database
|
||||
|
@ -75,7 +77,7 @@ class SpamBlacklistTest extends MediaWikiTestCase {
|
|||
'files' => [],
|
||||
] );
|
||||
|
||||
\MessageCache::singleton()->enable();
|
||||
MediaWikiServices::getInstance()->getMessageCache()->enable();
|
||||
$this->insertPage( 'MediaWiki:Spam-blacklist', implode( "\n", $this->blacklist ) );
|
||||
$this->insertPage( 'MediaWiki:Spam-whitelist', implode( "\n", $this->whitelist ) );
|
||||
|
||||
|
@ -87,7 +89,7 @@ class SpamBlacklistTest extends MediaWikiTestCase {
|
|||
}
|
||||
|
||||
protected function tearDown() : void {
|
||||
\MessageCache::singleton()->disable();
|
||||
MediaWikiServices::getInstance()->getMessageCache()->disable();
|
||||
parent::tearDown();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue