You are here

protected function EditorResourceTestBase::getExpectedNormalizedEntity in Drupal 8

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()

Returns the expected normalization of the entity.

Return value

array

Overrides EntityResourceTestBase::getExpectedNormalizedEntity

See also

::createEntity()

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(),
  ];
}