diff --git a/tests/src/Functional/LinkitBrowserTestBase.php b/tests/src/Functional/LinkitBrowserTestBase.php index bc61b6c..d6ff20f 100644 --- a/tests/src/Functional/LinkitBrowserTestBase.php +++ b/tests/src/Functional/LinkitBrowserTestBase.php @@ -14,7 +14,7 @@ abstract class LinkitBrowserTestBase extends BrowserTestBase { * * @var array */ - public static $modules = ['linkit', 'linkit_test', 'block']; + public static $modules = ['linkit', 'linkit_test', 'block', 'path_alias']; /** * {@inheritdoc} @@ -40,6 +40,9 @@ abstract class LinkitBrowserTestBase extends BrowserTestBase { */ protected function setUp() { parent::setUp(); + if ($this->container->get('entity_type.manager')->hasDefinition('path_alias')) { + $this->installEntitySchema('path_alias'); + } $this->placeBlock('page_title_block'); $this->placeBlock('local_tasks_block'); diff --git a/tests/src/Functional/LinkitUpdateTest.php b/tests/src/Functional/LinkitUpdateTest.php index 140fe12..592e657 100644 --- a/tests/src/Functional/LinkitUpdateTest.php +++ b/tests/src/Functional/LinkitUpdateTest.php @@ -30,6 +30,9 @@ class LinkitUpdateTest extends UpdatePathTestBase { */ protected function setUp() { parent::setUp(); + if ($this->container->get('entity_type.manager')->hasDefinition('path_alias')) { + $this->installEntitySchema('path_alias'); + } $this->configFactory = $this->container->get('config.factory'); } diff --git a/tests/src/FunctionalJavascript/LinkitDialogTest.php b/tests/src/FunctionalJavascript/LinkitDialogTest.php index 26eb74e..60cc99f 100644 --- a/tests/src/FunctionalJavascript/LinkitDialogTest.php +++ b/tests/src/FunctionalJavascript/LinkitDialogTest.php @@ -29,6 +29,7 @@ class LinkitDialogTest extends WebDriverTestBase { */ public static $modules = [ 'node', + 'path_alias', 'ckeditor', 'filter', 'linkit', @@ -60,6 +61,9 @@ class LinkitDialogTest extends WebDriverTestBase { */ protected function setUp() { parent::setUp(); + if ($this->container->get('entity_type.manager')->hasDefinition('path_alias')) { + $this->installEntitySchema('path_alias'); + } $matcherManager = $this->container->get('plugin.manager.linkit.matcher'); /** @var \Drupal\linkit\MatcherInterface $plugin */ diff --git a/tests/src/FunctionalJavascript/LinkitFormatAdminTest.php b/tests/src/FunctionalJavascript/LinkitFormatAdminTest.php index 7ab46ff..39d4d6e 100644 --- a/tests/src/FunctionalJavascript/LinkitFormatAdminTest.php +++ b/tests/src/FunctionalJavascript/LinkitFormatAdminTest.php @@ -28,6 +28,9 @@ class LinkitFormatAdminTest extends WebDriverTestBase { */ protected function setUp() { parent::setUp(); + if ($this->container->get('entity_type.manager')->hasDefinition('path_alias')) { + $this->installEntitySchema('path_alias'); + } $account = $this->drupalCreateUser([ 'administer filters', diff --git a/tests/src/Kernel/EntityMatcherDeriverTest.php b/tests/src/Kernel/EntityMatcherDeriverTest.php index cf3832a..f3c8b0c 100644 --- a/tests/src/Kernel/EntityMatcherDeriverTest.php +++ b/tests/src/Kernel/EntityMatcherDeriverTest.php @@ -12,7 +12,7 @@ class EntityMatcherDeriverTest extends LinkitKernelTestBase { /** * {@inheritdoc} */ - public static $modules = ['block', 'block_content', 'node', 'field']; + public static $modules = ['block', 'block_content', 'node', 'path_alias', 'field']; /** * The matcher manager. @@ -31,6 +31,9 @@ class EntityMatcherDeriverTest extends LinkitKernelTestBase { $this->installEntitySchema('block_content'); $this->installEntitySchema('node'); + if ($this->container->get('entity_type.manager')->hasDefinition('path_alias')) { + $this->installEntitySchema('path_alias'); + } $this->installConfig(['field', 'node']); $this->manager = $this->container->get('plugin.manager.linkit.matcher'); diff --git a/tests/src/Kernel/LinkitKernelTestBase.php b/tests/src/Kernel/LinkitKernelTestBase.php index d04a2bc..6ba9e2a 100644 --- a/tests/src/Kernel/LinkitKernelTestBase.php +++ b/tests/src/Kernel/LinkitKernelTestBase.php @@ -21,6 +21,7 @@ abstract class LinkitKernelTestBase extends KernelTestBase { 'user', 'filter', 'text', + 'path_alias', 'linkit', 'linkit_test', ]; diff --git a/tests/src/Kernel/Matchers/NodeMatcherTest.php b/tests/src/Kernel/Matchers/NodeMatcherTest.php index dc9439c..bbc0961 100644 --- a/tests/src/Kernel/Matchers/NodeMatcherTest.php +++ b/tests/src/Kernel/Matchers/NodeMatcherTest.php @@ -22,6 +22,7 @@ class NodeMatcherTest extends LinkitKernelTestBase { public static $modules = [ 'field', 'node', + 'path_alias', 'content_moderation', 'workflows', 'language', @@ -42,7 +43,10 @@ class NodeMatcherTest extends LinkitKernelTestBase { $this->installEntitySchema('node'); $this->installSchema('node', ['node_access']); - $this->installConfig(['field', 'node', 'language']); + $this->installConfig(['field', 'node', 'language', 'path_alias']); + if ($this->container->get('entity_type.manager')->hasDefinition('path_alias')) { + $this->installEntitySchema('path_alias'); + } $this->manager = $this->container->get('plugin.manager.linkit.matcher');