diff --git a/core/modules/file/lib/Drupal/file/Tests/FileListingTest.php b/core/modules/file/lib/Drupal/file/Tests/FileListingTest.php index 45fd3c9..4fc8072 100644 --- a/core/modules/file/lib/Drupal/file/Tests/FileListingTest.php +++ b/core/modules/file/lib/Drupal/file/Tests/FileListingTest.php @@ -89,7 +89,7 @@ function testFileListingPages() { $this->assertResponse(200); foreach ($nodes as $node) { - $file = entity_load('file', $node->file->fid); + $file = entity_load('file', $node->file->target_id); $this->assertText($file->getFilename()); $this->assertLinkByHref(file_create_url($file->getFileUri())); $this->assertLinkByHref('admin/content/files/usage/' . $file->id()); @@ -97,9 +97,9 @@ function testFileListingPages() { $this->assertFalse(preg_match('/views-field-status priority-low\">\s*' . t('Temporary') . '/', $this->drupalGetContent()), t('All files are stored as permanent.')); // Use one file two times and check usage information. - $orphaned_file = $nodes[1]->file->fid; - $used_file = $nodes[0]->file->fid; - $nodes[1]->file->fid = $used_file; + $orphaned_file = $nodes[1]->file->target_id; + $used_file = $nodes[0]->file->target_id; + $nodes[1]->file->target_id = $used_file; $nodes[1]->save(); $this->drupalGet('admin/content/files');