class ConfigInstallTest

Same name in this branch
  1. main core/tests/Drupal/KernelTests/Core/Config/ConfigInstallTest.php \Drupal\KernelTests\Core\Config\ConfigInstallTest
Same name and namespace in other branches
  1. 11.x core/tests/Drupal/KernelTests/Core/Config/ConfigInstallTest.php \Drupal\KernelTests\Core\Config\ConfigInstallTest
  2. 10 core/tests/Drupal/KernelTests/Core/Config/ConfigInstallTest.php \Drupal\KernelTests\Core\Config\ConfigInstallTest
  3. 9 core/tests/Drupal/KernelTests/Core/Config/ConfigInstallTest.php \Drupal\KernelTests\Core\Config\ConfigInstallTest
  4. 8.9.x core/tests/Drupal/KernelTests/Core/Config/ConfigInstallTest.php \Drupal\KernelTests\Core\Config\ConfigInstallTest
  5. 11.x core/modules/ckeditor5/tests/src/Functional/ConfigInstallTest.php \Drupal\Tests\ckeditor5\Functional\ConfigInstallTest

Tests installing a module that ships a CKEditor 5 editor in its config.

The test module is installed together with the profile's modules, before any theme is installed. The default theme in system.theme is already set at that point, so CKEditor 5 must not expect it to be installed.

@internal

Attributes

#[Group('ckeditor5')] #[RunTestsInSeparateProcesses]

Hierarchy

  • class \Drupal\Tests\ckeditor5\Functional\ConfigInstallTest extends \Drupal\Tests\BrowserTestBase

Expanded class hierarchy of ConfigInstallTest

See also

https://www.drupal.org/project/drupal/issues/3403394

File

core/modules/ckeditor5/tests/src/Functional/ConfigInstallTest.php, line 22

Namespace

Drupal\Tests\ckeditor5\Functional
View source
class ConfigInstallTest extends BrowserTestBase {
  
  /**
   * {@inheritdoc}
   */
  protected static $modules = [
    'ckeditor5_config_install_test',
  ];
  
  /**
   * {@inheritdoc}
   */
  protected $defaultTheme = 'stark';
  
  /**
   * Tests that the editor config is installed during site install.
   */
  public function testEditorInstalled() : void {
    $editor = \Drupal::entityTypeManager()->getStorage('editor')
      ->load('ckeditor5_config_install_test');
    $this->assertNotNull($editor);
    $this->assertSame('ckeditor5', $editor->getEditor());
  }

}

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