diff --git a/core/modules/menu/lib/Drupal/menu/Tests/MenuLanguageTest.php b/core/modules/menu/lib/Drupal/menu/Tests/MenuLanguageTest.php index 435c2e4..8fb9f94 100644 --- a/core/modules/menu/lib/Drupal/menu/Tests/MenuLanguageTest.php +++ b/core/modules/menu/lib/Drupal/menu/Tests/MenuLanguageTest.php @@ -194,4 +194,30 @@ function testMenuLanguageRemovedEnglish() { $this->assertEqual($menu->langcode, 'en'); } + /** + * Test whether the menu configuration language dropdown values are translated + */ + function testMenuLanguageConfigurationTranslated() { + // Create a test menu to test language settings. + // Machine name has to be lowercase. + $label = $this->randomString(); + $menu_name = Unicode::strtolower($this->randomName(16)); + $edit = array( + 'id' => $menu_name, + 'description' => '', + 'label' => $label, + 'langcode' => 'en', + ); + $this->drupalPost('admin/structure/menu/add', $edit, t('Save')); + + + $this->drupalGet("admin/structure/menu/manage/menu-" . $menu_name); + $options = $this->xpath('//select[@id=:id]/option', array(':id' => 'edit-langcode')); + $english = $this->xpath('//select[@id=:id]//option[@value=:option]', array(':id' => 'edit-langcode', ':option' => 'en')); + foreach($english as $key=>$value) { + debug($key); + debug($value); + } + #$this->assertOption('', ''); + } }