function ComponentInvalidReplacementTest::testInvalidDefinitionTheme

Same name in this branch
  1. 11.x core/tests/Drupal/KernelTests/Components/ComponentInvalidReplacementTest.php \Drupal\KernelTests\Components\ComponentInvalidReplacementTest::testInvalidDefinitionTheme()
Same name in other branches
  1. 10 core/modules/sdc/tests/src/Kernel/ComponentInvalidReplacementTest.php \Drupal\Tests\sdc\Kernel\ComponentInvalidReplacementTest::testInvalidDefinitionTheme()
  2. 10 core/tests/Drupal/KernelTests/Components/ComponentInvalidReplacementTest.php \Drupal\KernelTests\Components\ComponentInvalidReplacementTest::testInvalidDefinitionTheme()

Ensure that component replacement validates the schema compatibility.

File

core/modules/sdc/tests/src/Kernel/ComponentInvalidReplacementTest.php, line 29

Class

ComponentInvalidReplacementTest
Tests invalid render options for components.

Namespace

Drupal\Tests\sdc\Kernel

Code

public function testInvalidDefinitionTheme() : void {
    $this->expectException(IncompatibleComponentSchema::class);
    $this->manager
        ->getDefinitions();
}

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