diff --git a/core/lib/Drupal/Core/Display/VariantBase.php b/core/lib/Drupal/Core/Display/VariantBase.php index 5f56b4d700..be10780209 100644 --- a/core/lib/Drupal/Core/Display/VariantBase.php +++ b/core/lib/Drupal/Core/Display/VariantBase.php @@ -2,9 +2,9 @@ namespace Drupal\Core\Display; -use Drupal\Component\Plugin\ConfigurablePluginBase; use Drupal\Core\Cache\RefinableCacheableDependencyTrait; use Drupal\Core\Form\FormStateInterface; +use Drupal\Core\Plugin\ConfigurablePluginBase; use Drupal\Core\Plugin\PluginDependencyTrait; use Drupal\Core\Session\AccountInterface; diff --git a/core/lib/Drupal/Core/Layout/LayoutDefault.php b/core/lib/Drupal/Core/Layout/LayoutDefault.php index 0d2a8ea7b3..f1682e3515 100644 --- a/core/lib/Drupal/Core/Layout/LayoutDefault.php +++ b/core/lib/Drupal/Core/Layout/LayoutDefault.php @@ -2,7 +2,7 @@ namespace Drupal\Core\Layout; -use Drupal\Component\Plugin\ConfigurablePluginBase; +use Drupal\Core\Plugin\ConfigurablePluginBase; /** * Provides a default class for Layout plugins. diff --git a/core/lib/Drupal/Component/Plugin/ConfigurablePluginBase.php b/core/lib/Drupal/Core/Plugin/ConfigurablePluginBase.php similarity index 85% rename from core/lib/Drupal/Component/Plugin/ConfigurablePluginBase.php rename to core/lib/Drupal/Core/Plugin/ConfigurablePluginBase.php index e28389ad01..44547862b5 100644 --- a/core/lib/Drupal/Component/Plugin/ConfigurablePluginBase.php +++ b/core/lib/Drupal/Core/Plugin/ConfigurablePluginBase.php @@ -1,8 +1,8 @@ setConfiguration($configuration); + } + /** * {@inheritdoc} */ diff --git a/core/tests/Drupal/Tests/Core/Plugin/Fixtures/TestConfigurablePlugin.php b/core/tests/Drupal/Tests/Core/Plugin/Fixtures/TestConfigurablePlugin.php index 458c0fb275..e49319d495 100644 --- a/core/tests/Drupal/Tests/Core/Plugin/Fixtures/TestConfigurablePlugin.php +++ b/core/tests/Drupal/Tests/Core/Plugin/Fixtures/TestConfigurablePlugin.php @@ -2,11 +2,30 @@ namespace Drupal\Tests\Core\Plugin\Fixtures; -use Drupal\Component\Plugin\ConfigurablePluginBase; +use Drupal\Component\Plugin\ConfigurablePluginInterface; +use Drupal\Component\Plugin\PluginBase; +use Drupal\Core\Plugin\ConfigurablePluginTrait; /** - * A class to test configurable plugins. + * A fixture to test Configurable Plugins. */ -class TestConfigurablePlugin extends ConfigurablePluginBase { +class TestConfigurablePlugin extends PluginBase implements ConfigurablePluginInterface { + + use ConfigurablePluginTrait; + + /** + * {@inheritdoc} + */ + public function __construct(array $configuration, $plugin_id, $plugin_definition) { + parent::__construct($configuration, $plugin_id, $plugin_definition); + $this->setConfiguration($configuration); + } + + /** + * {@inheritdoc} + */ + public function calculateDependencies() { + return []; + } }