4 * Base class that store and restore the Language objects
6 abstract class MediaWikiLangTestCase
extends MediaWikiTestCase
{
7 protected function setUp() {
8 global $wgLanguageCode, $wgContLang;
10 if ( $wgLanguageCode != $wgContLang->getCode() ) {
11 throw new MWException( "Error in MediaWikiLangTestCase::setUp(): " .
12 "\$wgLanguageCode ('$wgLanguageCode') is different from " .
13 "\$wgContLang->getCode() (" . $wgContLang->getCode() . ")" );
18 $this->setUserLang( 'en' );
19 // For mainpage to be 'Main Page'
20 $this->setContentLang( 'en' );
22 MessageCache
::singleton()->disable();