diff --git a/core/modules/shortcut/shortcut.install b/core/modules/shortcut/shortcut.install index 73986b8..8df408f 100644 --- a/core/modules/shortcut/shortcut.install +++ b/core/modules/shortcut/shortcut.install @@ -64,6 +64,6 @@ function shortcut_uninstall() { // Theme settings are not configuration entities and cannot depend on modules // so to unset a module-specific setting, we need to unset it with logic. if (\Drupal::service('theme_handler')->themeExists('seven')) { - \Drupal::configFactory()->getEditable('seven.settings')->clear('third_party_settings.shortcut.module_link')->save(TRUE); + \Drupal::configFactory()->getEditable('seven.settings')->clear('third_party_settings.shortcut')->save(TRUE); } } diff --git a/core/modules/shortcut/tests/src/Kernel/ShortcutSevenIntegrationTest.php b/core/modules/shortcut/tests/src/Kernel/ShortcutSevenIntegrationTest.php new file mode 100644 index 0000000..928a7a5 --- /dev/null +++ b/core/modules/shortcut/tests/src/Kernel/ShortcutSevenIntegrationTest.php @@ -0,0 +1,36 @@ +install(['seven']); + $this->assertNull($this->config('seven.settings')->get('third_party_settings.shortcut'), 'There are no shortcut settings in seven.settings.'); + + \Drupal::service('module_installer')->install(['shortcut']); + $this->assertNotNull($this->config('seven.settings')->get('third_party_settings.shortcut'), 'There are shortcut settings in seven.settings.'); + + \Drupal::service('module_installer')->uninstall(['shortcut']); + $this->assertNull($this->config('seven.settings')->get('third_party_settings.shortcut'), 'There are no shortcut settings in seven.settings.'); + } + +}