function FileFieldTestCase::assertFileExists

7.x file.test FileFieldTestCase::assertFileExists($file, $message = NULL)

Asserts that a file exists physically on disk.

7 calls to FileFieldTestCase::assertFileExists()
FileFieldRevisionTestCase::testRevisions in drupal-7.x/modules/file/tests/file.test
Tests creating multiple revisions of a node and managing attached files.
FileFieldValidateTestCase::testFileExtension in drupal-7.x/modules/file/tests/file.test
Tests file extension checking.
FileFieldValidateTestCase::testFileMaxSize in drupal-7.x/modules/file/tests/file.test
Tests the max file size validator.
FileFieldValidateTestCase::testRequired in drupal-7.x/modules/file/tests/file.test
Tests the required property on file fields.
FileFieldWidgetTestCase::testPrivateFileComment in drupal-7.x/modules/file/tests/file.test
Tests that download restrictions on private files work on comments.

... See full list

File

drupal-7.x/modules/file/tests/file.test, line 182
Tests for file.module.

Class

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

Code

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