function LoadTest::testLoadMissingFid

Try to load a non-existent file by fid.

File

drupal/core/modules/file/lib/Drupal/file/Tests/LoadTest.php, line 25
Definition of Drupal\file\Tests\LoadTest.

Class

LoadTest
Tests the file_load() function.

Namespace

Drupal\file\Tests

Code

function testLoadMissingFid() {
  $this
    ->assertFalse(file_load(-1), t("Try to load an invalid fid fails."));
  $this
    ->assertFileHooksCalled(array());
}