X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=tests%2Fphpunit%2Fincludes%2Fpage%2FArticleTablesTest.php;h=34b25251c1a36fd809ea782ac28d31d706800c7d;hb=e4b775acf113d021ce35f69a177d7444b8ed8412;hp=d88592600fd8daa5ee31af880ed539ffd0bcf4f5;hpb=734ca2b4d2a1246fb0ea1e54b861ab423ab5e257;p=lhc%2Fweb%2Fwiklou.git diff --git a/tests/phpunit/includes/page/ArticleTablesTest.php b/tests/phpunit/includes/page/ArticleTablesTest.php index d88592600f..34b25251c1 100644 --- a/tests/phpunit/includes/page/ArticleTablesTest.php +++ b/tests/phpunit/includes/page/ArticleTablesTest.php @@ -5,7 +5,7 @@ */ class ArticleTablesTest extends MediaWikiLangTestCase { /** - * Make sure that bug 14404 doesn't strike again. We don't want + * Make sure that T16404 doesn't strike again. We don't want * templatelinks based on the user language when {{int:}} is used, only the * content language. * @@ -13,30 +13,29 @@ class ArticleTablesTest extends MediaWikiLangTestCase { * @covers Title::getLinksFrom */ public function testTemplatelinksUsesContentLanguage() { - $title = Title::newFromText( 'Bug 14404' ); + $title = Title::newFromText( 'T16404' ); $page = WikiPage::factory( $title ); $user = new User(); $user->mRights = [ 'createpage', 'edit', 'purge' ]; - $this->setMwGlobals( 'wgLanguageCode', 'es' ); - $this->setMwGlobals( 'wgContLang', Language::factory( 'es' ) ); - $this->setMwGlobals( 'wgLang', Language::factory( 'fr' ) ); + $this->setContentLang( 'es' ); + $this->setUserLang( 'fr' ); $page->doEditContent( new WikitextContent( '{{:{{int:history}}}}' ), - 'Test code for bug 14404', + 'Test code for T16404', 0, false, $user ); $templates1 = $title->getTemplateLinksFrom(); - $this->setMwGlobals( 'wgLang', Language::factory( 'de' ) ); + $this->setUserLang( 'de' ); $page = WikiPage::factory( $title ); // In order to force the re-rendering of the same wikitext // We need an edit, a purge is not enough to regenerate the tables $page->doEditContent( new WikitextContent( '{{:{{int:history}}}}' ), - 'Test code for bug 14404', + 'Test code for T16404', EDIT_UPDATE, false, $user