diff options
author | Pierre Schmitz <pierre@archlinux.de> | 2014-04-25 06:26:49 +0200 |
---|---|---|
committer | Pierre Schmitz <pierre@archlinux.de> | 2014-04-25 06:26:49 +0200 |
commit | 2e44b49a2db3026050b136de9b00f749dd3ff939 (patch) | |
tree | ef048f4db79a93c25cfc86319264aa7ae2a4ae0b /tests/phpunit/MediaWikiLangTestCase.php | |
parent | 9441dde8bfb95277df073717ed7817dced40f948 (diff) |
Update to MediaWiki 1.22.6
Diffstat (limited to 'tests/phpunit/MediaWikiLangTestCase.php')
-rw-r--r-- | tests/phpunit/MediaWikiLangTestCase.php | 33 |
1 files changed, 0 insertions, 33 deletions
diff --git a/tests/phpunit/MediaWikiLangTestCase.php b/tests/phpunit/MediaWikiLangTestCase.php deleted file mode 100644 index 1131385f..00000000 --- a/tests/phpunit/MediaWikiLangTestCase.php +++ /dev/null @@ -1,33 +0,0 @@ -<?php - -/** - * Base class that store and restore the Language objects - */ -abstract class MediaWikiLangTestCase extends MediaWikiTestCase { - - protected function setUp() { - global $wgLanguageCode, $wgContLang; - parent::setUp(); - - if ( $wgLanguageCode != $wgContLang->getCode() ) { - throw new MWException( "Error in MediaWikiLangTestCase::setUp(): " . - "\$wgLanguageCode ('$wgLanguageCode') is different from " . - "\$wgContLang->getCode() (" . $wgContLang->getCode() . ")" ); - } - - // HACK: Call getLanguage() so the real $wgContLang is cached as the user language - // rather than our fake one. This is to avoid breaking other, unrelated tests. - RequestContext::getMain()->getLanguage(); - - $langCode = 'en'; # For mainpage to be 'Main Page' - $langObj = Language::factory( $langCode ); - - $this->setMwGlobals( array( - 'wgLanguageCode' => $langCode, - 'wgLang' => $langObj, - 'wgContLang' => $langObj, - ) ); - - MessageCache::singleton()->disable(); - } -} |