function MenuLinkContentTranslationUITest::testTranslationLinkOnMenuEditForm
Same name in other branches
- 9 core/modules/menu_link_content/tests/src/Functional/MenuLinkContentTranslationUITest.php \Drupal\Tests\menu_link_content\Functional\MenuLinkContentTranslationUITest::testTranslationLinkOnMenuEditForm()
- 8.9.x core/modules/menu_link_content/tests/src/Functional/MenuLinkContentTranslationUITest.php \Drupal\Tests\menu_link_content\Functional\MenuLinkContentTranslationUITest::testTranslationLinkOnMenuEditForm()
- 11.x core/modules/menu_link_content/tests/src/Functional/MenuLinkContentTranslationUITest.php \Drupal\Tests\menu_link_content\Functional\MenuLinkContentTranslationUITest::testTranslationLinkOnMenuEditForm()
Ensure that a translate link can be found on the menu edit form.
File
-
core/
modules/ menu_link_content/ tests/ src/ Functional/ MenuLinkContentTranslationUITest.php, line 75
Class
- MenuLinkContentTranslationUITest
- Tests the menu link content translation UI.
Namespace
Drupal\Tests\menu_link_content\FunctionalCode
public function testTranslationLinkOnMenuEditForm() : void {
$this->drupalGet('admin/structure/menu/manage/tools');
$this->assertSession()
->linkNotExists('Translate');
$menu_link_content = MenuLinkContent::create([
'menu_name' => 'tools',
'link' => [
'uri' => 'internal:/admin/structure/menu',
],
'title' => 'Link test',
]);
$menu_link_content->save();
$this->drupalGet('admin/structure/menu/manage/tools');
$this->assertSession()
->linkExists('Translate');
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.