function FileFieldTestBase::assertFileNotExists

Asserts that a file does not exist on disk.

1 call to FileFieldTestBase::assertFileNotExists()
FileFieldRevisionTest::testRevisions in drupal/core/modules/file/lib/Drupal/file/Tests/FileFieldRevisionTest.php
Tests creating multiple revisions of a node and managing attached files.

File

drupal/core/modules/file/lib/Drupal/file/Tests/FileFieldTestBase.php, line 219
Definition of Drupal\file\Tests\FileFieldTestBase.

Class

FileFieldTestBase
Provides methods specifically for testing File module's field handling.

Namespace

Drupal\file\Tests

Code

function assertFileNotExists($file, $message = NULL) {
  $message = isset($message) ? $message : t('File %file exists on the disk.', array(
    '%file' => $file->uri,
  ));
  $this
    ->assertFalse(is_file($file->uri), $message);
}