Merge "Revert "Log the reason why revision->getContent() returns null""
[lhc/web/wiklou.git] / tests / phpunit / includes / filerepo / file / LocalFileTest.php
index 3c5754b..e25e606 100644 (file)
@@ -12,24 +12,24 @@ class LocalFileTest extends MediaWikiTestCase {
 
                $this->setMwGlobals( 'wgCapitalLinks', true );
 
-               $info = array(
+               $info = [
                        'name' => 'test',
                        'directory' => '/testdir',
                        'url' => '/testurl',
                        'hashLevels' => 2,
                        'transformVia404' => false,
-                       'backend' => new FSFileBackend( array(
+                       'backend' => new FSFileBackend( [
                                'name' => 'local-backend',
-                               'wikiId' => wfWikiId(),
-                               'containerPaths' => array(
+                               'wikiId' => wfWikiID(),
+                               'containerPaths' => [
                                        'cont1' => "/testdir/local-backend/tempimages/cont1",
                                        'cont2' => "/testdir/local-backend/tempimages/cont2"
-                               )
-                       ) )
-               );
-               $this->repo_hl0 = new LocalRepo( array( 'hashLevels' => 0 ) + $info );
-               $this->repo_hl2 = new LocalRepo( array( 'hashLevels' => 2 ) + $info );
-               $this->repo_lc = new LocalRepo( array( 'initialCapital' => false ) + $info );
+                               ]
+                       ] )
+               ];
+               $this->repo_hl0 = new LocalRepo( [ 'hashLevels' => 0 ] + $info );
+               $this->repo_hl2 = new LocalRepo( [ 'hashLevels' => 2 ] + $info );
+               $this->repo_lc = new LocalRepo( [ 'initialCapital' => false ] + $info );
                $this->file_hl0 = $this->repo_hl0->newFile( 'test!' );
                $this->file_hl2 = $this->repo_hl2->newFile( 'test!' );
                $this->file_lc = $this->repo_lc->newFile( 'test!' );
@@ -176,7 +176,7 @@ class LocalFileTest extends MediaWikiTestCase {
                $file = wfLocalFile( "File:Some_file_that_probably_doesn't exist.png" );
                $this->assertThat(
                        $file,
-                       $this->isInstanceOf( 'LocalFile' ),
+                       $this->isInstanceOf( LocalFile::class ),
                        'wfLocalFile() returns LocalFile for valid Titles'
                );
        }