function ImageUploadTest::getUploadUrl
Same name in other branches
- 9 core/modules/ckeditor5/tests/src/Functional/ImageUploadTest.php \Drupal\Tests\ckeditor5\Functional\ImageUploadTest::getUploadUrl()
- 10 core/modules/ckeditor5/tests/src/Functional/ImageUploadTest.php \Drupal\Tests\ckeditor5\Functional\ImageUploadTest::getUploadUrl()
Provides the image upload URL.
Return value
\Drupal\Core\Url The upload image URL for the basic_html format.
4 calls to ImageUploadTest::getUploadUrl()
- ImageUploadAccessTest::testCkeditor5ImageUploadRoute in core/
modules/ ckeditor5/ tests/ src/ Functional/ ImageUploadAccessTest.php - Test access to the CKEditor 5 image upload controller.
- ImageUploadTest::testFileUploadLargerFileSize in core/
modules/ ckeditor5/ tests/ src/ Functional/ ImageUploadTest.php - Tests using the file upload route with a file size larger than allowed.
- ImageUploadTest::testLockAfterFailedValidation in core/
modules/ ckeditor5/ tests/ src/ Functional/ ImageUploadTest.php - Test that lock is removed after a failed validation.
- ImageUploadTest::testUploadFileExtension in core/
modules/ ckeditor5/ tests/ src/ Functional/ ImageUploadTest.php - Tests using the file upload route with a disallowed extension.
File
-
core/
modules/ ckeditor5/ tests/ src/ Functional/ ImageUploadTest.php, line 186
Class
- ImageUploadTest
- Test image upload.
Namespace
Drupal\Tests\ckeditor5\FunctionalCode
protected function getUploadUrl() {
$token = $this->container
->get('csrf_token')
->get('ckeditor5/upload-image/basic_html');
return Url::fromRoute('ckeditor5.upload_image', [
'editor' => 'basic_html',
], [
'query' => [
'token' => $token,
],
]);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.