function EditorResourceTestBase::getExpectedNormalizedEntity

Same name and namespace in other branches
  1. 9 core/modules/editor/tests/src/Functional/Rest/EditorResourceTestBase.php \Drupal\Tests\editor\Functional\Rest\EditorResourceTestBase::getExpectedNormalizedEntity()
  2. 10 core/modules/editor/tests/src/Functional/Rest/EditorResourceTestBase.php \Drupal\Tests\editor\Functional\Rest\EditorResourceTestBase::getExpectedNormalizedEntity()
  3. 11.x core/modules/editor/tests/src/Functional/Rest/EditorResourceTestBase.php \Drupal\Tests\editor\Functional\Rest\EditorResourceTestBase::getExpectedNormalizedEntity()

Overrides EntityResourceTestBase::getExpectedNormalizedEntity

File

core/modules/editor/tests/src/Functional/Rest/EditorResourceTestBase.php, line 83

Class

EditorResourceTestBase
ResourceTestBase for Editor entity.

Namespace

Drupal\Tests\editor\Functional\Rest

Code

protected function getExpectedNormalizedEntity() {
    return [
        'dependencies' => [
            'config' => [
                'filter.format.llama',
            ],
            'module' => [
                'ckeditor',
            ],
        ],
        'editor' => 'ckeditor',
        'format' => 'llama',
        'image_upload' => [
            'status' => FALSE,
            'scheme' => 'public',
            'directory' => 'inline-images',
            'max_size' => '',
            'max_dimensions' => [
                'width' => NULL,
                'height' => NULL,
            ],
        ],
        'langcode' => 'en',
        'settings' => [
            'toolbar' => [
                'rows' => [
                    [
                        [
                            'name' => 'Formatting',
                            'items' => [
                                'Bold',
                                'Italic',
                            ],
                        ],
                        [
                            'name' => 'Links',
                            'items' => [
                                'DrupalLink',
                                'DrupalUnlink',
                            ],
                        ],
                        [
                            'name' => 'Lists',
                            'items' => [
                                'BulletedList',
                                'NumberedList',
                            ],
                        ],
                        [
                            'name' => 'Media',
                            'items' => [
                                'Blockquote',
                                'DrupalImage',
                            ],
                        ],
                        [
                            'name' => 'Tools',
                            'items' => [
                                'Source',
                            ],
                        ],
                    ],
                ],
            ],
            'plugins' => [
                'language' => [
                    'language_list' => 'un',
                ],
            ],
        ],
        'status' => TRUE,
        'uuid' => $this->entity
            ->uuid(),
    ];
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.