diff --git a/composer.json b/composer.json index 61f75a24..c8c65b14 100644 --- a/composer.json +++ b/composer.json @@ -54,10 +54,7 @@ "Drupal\\Exception": "src/", "Drupal\\DrupalExtension": "src/", "Drupal\\MinkExtension": "src/" - }, - "classmap": [ - "src/Drupal/DocumentElement.php" - ] + } }, "extra": { "branch-alias": { diff --git a/src/Drupal/DrupalExtension/ServiceContainer/DrupalExtension.php b/src/Drupal/DrupalExtension/ServiceContainer/DrupalExtension.php index 1e115a07..5f44f61a 100644 --- a/src/Drupal/DrupalExtension/ServiceContainer/DrupalExtension.php +++ b/src/Drupal/DrupalExtension/ServiceContainer/DrupalExtension.php @@ -67,6 +67,7 @@ public function load(ContainerBuilder $container, array $config) // of the page, pieces of texts inside the section. // @see https://github.com/minkphp/MinkBrowserKitDriver/issues/153 // @see https://www.drupal.org/project/drupal/issues/3175718 + require_once(__DIR__ . '/../../DocumentElement.php'); class_alias('\Drupal\DocumentElement', '\Behat\Mink\Element\DocumentElement', true); $loader = new YamlFileLoader($container, new FileLocator(__DIR__ . '/config'));