MessageCache::destroyInstance() is static.
authorAlexandre Emsenhuber <ialex.wiki@gmail.com>
Thu, 16 Aug 2012 08:00:45 +0000 (10:00 +0200)
committerAlexandre Emsenhuber <ialex.wiki@gmail.com>
Thu, 16 Aug 2012 08:00:45 +0000 (10:00 +0200)
So there is no point calling it using
MessageCache::singleton()->destroyInstance()

Change-Id: Ie4e10284b4b911fff018c52a2a680452601f8288

tests/phpunit/includes/parser/NewParserTest.php

index 0380152..ff6e472 100644 (file)
@@ -186,7 +186,7 @@ class NewParserTest extends MediaWikiTestCase {
                if ( !$this->db->selectField( 'image', '1', array( 'img_name' => $image->getName() ) ) ) {
                        $image->recordUpload2(
                                '', // archive name
-                               'Upload of some lame file', 
+                               'Upload of some lame file',
                                'Some lame file',
                                array(
                                        'size'        => 12345,
@@ -197,7 +197,7 @@ class NewParserTest extends MediaWikiTestCase {
                                        'mime'        => 'image/jpeg',
                                        'metadata'    => serialize( array() ),
                                        'sha1'        => wfBaseConvert( '', 16, 36, 31 ),
-                                       'fileExists'  => true ), 
+                                       'fileExists'  => true ),
                                $this->db->timestamp( '20010115123500' ), $user
                        );
                }
@@ -207,8 +207,8 @@ class NewParserTest extends MediaWikiTestCase {
                if ( !$this->db->selectField( 'image', '1', array( 'img_name' => $image->getName() ) ) ) {
                        $image->recordUpload2(
                                '', // archive name
-                               'zomgnotcensored', 
-                               'Borderline image', 
+                               'zomgnotcensored',
+                               'Borderline image',
                                array(
                                        'size'        => 12345,
                                        'width'       => 320,
@@ -218,7 +218,7 @@ class NewParserTest extends MediaWikiTestCase {
                                        'mime'        => 'image/jpeg',
                                        'metadata'    => serialize( array() ),
                                        'sha1'        => wfBaseConvert( '', 16, 36, 31 ),
-                                       'fileExists'  => true ), 
+                                       'fileExists'  => true ),
                                $this->db->timestamp( '20010115123500' ), $user
                        );
                }
@@ -383,7 +383,7 @@ class NewParserTest extends MediaWikiTestCase {
                # The entries saved into RepoGroup cache with previous globals will be wrong.
                RepoGroup::destroySingleton();
                FileBackendGroup::destroySingleton();
-               MessageCache::singleton()->destroyInstance();
+               MessageCache::destroyInstance();
 
                return $context;
        }