function FileResourceTestBase::fileResourceTestBaseSkipTests
Same name in other branches
- 10 core/modules/file/tests/src/Functional/Rest/FileResourceTestBase.php \Drupal\Tests\file\Functional\Rest\FileResourceTestBase::fileResourceTestBaseSkipTests()
Marks some tests as skipped because XML cannot be deserialized.
File
-
core/
modules/ file/ tests/ src/ Functional/ Rest/ FileResourceTestBase.php, line 48
Class
Namespace
Drupal\Tests\file\Functional\RestCode
public function fileResourceTestBaseSkipTests() : void {
if ($this->name() === 'testPost') {
// Drupal does not allow creating file entities independently. It allows
// you to create file entities that are referenced from another entity
// (e.g. an image for a node's image field).
// For that purpose, there is the "file_upload" REST resource plugin.
// @see \Drupal\file\FileAccessControlHandler::checkCreateAccess()
// @see \Drupal\file\Plugin\rest\resource\FileUploadResource
$this->markTestSkipped('Drupal does not allow creating file entities independently.');
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.