function OverrideMenuLinksConfigActionTest::testConfigName
Tests that the action only works on core.menu.static_menu_link_overrides.
File
-
core/
tests/ Drupal/ KernelTests/ Core/ Menu/ OverrideMenuLinksConfigActionTest.php, line 34
Class
- OverrideMenuLinksConfigActionTest
- Tests overriding static menu links with config actions.
Namespace
Drupal\KernelTests\Core\MenuCode
public function testConfigName() : void {
$this->expectException(ConfigActionException::class);
$this->expectExceptionMessage('This config action can only be used on the core.menu.static_menu_link_overrides config object.');
$this->container
->get('plugin.manager.config_action')
->applyAction('overrideMenuLinks', 'system.menu.original', []);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.