Warn if stateful ParserOutput transforms are used
[lhc/web/wiklou.git] / tests / phpunit / MediaWikiLangTestCase.php
1 <?php
2
3 /**
4 * Base class that store and restore the Language objects
5 */
6 abstract class MediaWikiLangTestCase extends MediaWikiTestCase {
7 protected function setUp() {
8 global $wgLanguageCode, $wgContLang;
9
10 if ( $wgLanguageCode != $wgContLang->getCode() ) {
11 throw new MWException( "Error in MediaWikiLangTestCase::setUp(): " .
12 "\$wgLanguageCode ('$wgLanguageCode') is different from " .
13 "\$wgContLang->getCode() (" . $wgContLang->getCode() . ")" );
14 }
15
16 parent::setUp();
17
18 $this->setUserLang( 'en' );
19 // For mainpage to be 'Main Page'
20 $this->setContentLang( 'en' );
21
22 MessageCache::singleton()->disable();
23 }
24 }