Merge branch 'Wikidata' into master.
[lhc/web/wiklou.git] / tests / phpunit / includes / TimestampTest.php
index 2dd02e3..6352160 100644 (file)
@@ -4,6 +4,16 @@
  * Tests timestamp parsing and output.
  */
 class TimestampTest extends MediaWikiTestCase {
+
+       protected function setUp() {
+               parent::setUp();
+
+               $this->setMwGlobals( array(
+                       'wgLanguageCode' => 'en',
+                       'wgContLang' => Language::factory( 'en' ),
+                       'wgLang' => Language::factory( 'en' ),
+               ) );
+       }
        /**
         * Test parsing of valid timestamps and outputing to MW format.
         * @dataProvider provideValidTimestamps
@@ -51,7 +61,7 @@ class TimestampTest extends MediaWikiTestCase {
         * Returns a list of valid timestamps in the format:
         * array( type, timestamp_of_type, timestamp_in_MW )
         */
-       function provideValidTimestamps() {
+       public static function provideValidTimestamps() {
                return array(
                        // Various formats
                        array( TS_UNIX, '1343761268', '20120731190108' ),