mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Linter
synced 2024-11-27 09:10:05 +00:00
Avoid using WikiPage::factory()
WikiPage::factory() is deprecated since 1.36 and should be replaced with WikiPageFactory::newFromTitle(). Bug: T297688 Change-Id: I63bf3ba1c2ad6f8b59d369d91777af0418746a6b
This commit is contained in:
parent
b33485da62
commit
9a1ce6e392
|
@ -26,7 +26,6 @@ use MediaWiki\Linter\LintError;
|
|||
use MediaWiki\Linter\RecordLintJob;
|
||||
use Title;
|
||||
use User;
|
||||
use WikiPage;
|
||||
|
||||
/**
|
||||
* @group Database
|
||||
|
@ -47,7 +46,7 @@ class RecordLintJobTest extends \MediaWikiIntegrationTestCase {
|
|||
if ( $user->getId() === 0 ) {
|
||||
$user->addToDatabase();
|
||||
}
|
||||
$page = WikiPage::factory( $title );
|
||||
$page = $this->getServiceContainer()->getWikiPageFactory()->newFromTitle( $title );
|
||||
|
||||
$content = ContentHandler::makeContent( $baseText, $title );
|
||||
$page->doUserEditContent( $content, $user, "base text for test" );
|
||||
|
|
Loading…
Reference in a new issue