diff --git a/core/modules/menu/lib/Drupal/menu/Tests/MenuLanguageTest.php b/core/modules/menu/lib/Drupal/menu/Tests/MenuLanguageTest.php deleted file mode 100644 index da6c1e9..0000000 --- a/core/modules/menu/lib/Drupal/menu/Tests/MenuLanguageTest.php +++ /dev/null @@ -1,124 +0,0 @@ - 'Menu language', - 'description' => 'Create menu in non-English language and menu link item.', - 'group' => 'Menu' - ); - } - - function setUp() { - parent::setUp(); - - // Create user. - $this->admin_user = $this->drupalCreateUser(array('access administration pages', 'administer menu')); - $this->drupalLogin($this->admin_user); - - // Add some custom languages. - $language = new Language(array( - 'langcode' => 'aa', - 'name' => $this->randomName(), - )); - language_save($language); - } - - /** - * Tests menu language settings. - */ - function testMenuLanguage() { - // Create a test menu to decouple looking for Translate operations - // link so this does not test more than necessary. - $this->drupalGet('admin/structure/menu/add'); - // Lowercase the machine name. Find the issue that is supposed to be making - // randomMachineName(). - $menu_name = drupal_strtolower($this->randomName(16)); - $label = $this->randomName(16); - $edit = array( - 'id' => $menu_name, - 'description' => '', - 'label' => $label, - ); - // Assert the new menu is in that language and the default menu link info. - //$this->assertRaw($label, 'Custom menu was added.'); - // Assert menu langcode aa. - // Assert default_menu_links_language langcode bb. - // Assert default_menu_links_language language_show TRUE. - - // Edit menu link. - // Assert language select is there with default bb. - // $this->assertMenuLink($menu_link->id(), array('menu_name' => $menu_name, 'link_path' => $link, 'has_children' => 0, 'plid' => $plid)); - -/* - // Edit menu to change default menu link item language. - $menu = entity_edit('menu', array( - 'langcode' => 'cc', - )); - $edit = array( - 'link_path' => '', - 'link_title' => $title, - 'description' => '', - 'parent' => $menu_name . ':' . 0, - ); - // Add menu link. - $this->drupalPost(NULL, $edit, t('Save')); - - $menu_links = entity_load_multiple_by_properties('menu_link', array('link_title' => $title)); - $menu_link = reset($menu_links); - $menu->save(); - $this->drupalGet('admin/structure/menu/manage/' . $menu_name); - - // Edit menu link. - // Assert language select is there with default cc. - // $this->assertMenuLink($menu_link->id(), array('menu_name' => $menu_name, 'link_path' => $link, 'has_children' => 0, 'plid' => $plid)); - - // Edit menu to change hide language select on menu link item add. - $edit = array( - 'link_path' => '', - 'link_title' => $title, - 'description' => '', - 'parent' => $menu_name . ':' . 0, - ); - // Add menu link. - $this->drupalPost(NULL, $edit, t('Save')); - - $menu_links = entity_load_multiple_by_properties('menu_link', array('link_title' => $title)); - $menu_link = reset($menu_links); - $this->drupalGet('admin/structure/menu/manage/' . $menu_name); - - // Edit menu link. - $this->drupalGet("admin/structure/menu/manage/$menu_name/edit"); - - $title = '!link_' . $this->randomName(16); -*/ - // Assert language select not present. - // $this->assertMenuLink($menu_link->id(), array('menu_name' => $menu_name, 'link_path' => $link, 'has_children' => 0, 'plid' => $plid)); - - // Delete custom menu. - // @todo Make an issue to add tests for deleting, and verifying config is - // also removed. - } - -}