core security update
This commit is contained in:
@@ -72,6 +72,17 @@ class MenuTestCase extends DrupalWebTestCase {
|
||||
$saved_item = menu_link_load($item['mlid']);
|
||||
$this->assertEqual($description, $saved_item['options']['attributes']['title'], 'Saving an existing link updates the description (title attribute)');
|
||||
$this->resetMenuLink($item, $old_title);
|
||||
|
||||
// Test that the page title is correct when a local task appears in a
|
||||
// top-level menu item. See https://www.drupal.org/node/1973262.
|
||||
$item = $this->addMenuLink(0, 'user/register', 'user-menu');
|
||||
$this->drupalGet('user/password');
|
||||
$this->assertNoTitle('Home | Drupal');
|
||||
$this->drupalLogout();
|
||||
$this->drupalGet('user/register');
|
||||
$this->assertTitle($item['link_title'] . ' | Drupal');
|
||||
$this->drupalGet('user');
|
||||
$this->assertNoTitle('Home | Drupal');
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -637,7 +648,12 @@ class MenuNodeTestCase extends DrupalWebTestCase {
|
||||
);
|
||||
$this->drupalPost('admin/structure/types/manage/page', $edit, t('Save content type'));
|
||||
|
||||
// Create a node.
|
||||
// Verify that the menu link title on the node add form has the correct
|
||||
// maxlength.
|
||||
$this->drupalGet('node/add/page');
|
||||
$this->assertPattern('/<input .* id="edit-menu-link-title" .* maxlength="255" .* \/>/', 'Menu link title field has correct maxlength in node add form.');
|
||||
|
||||
// Create a node with menu link disabled.
|
||||
$node_title = $this->randomName();
|
||||
$language = LANGUAGE_NONE;
|
||||
$edit = array(
|
||||
@@ -673,6 +689,10 @@ class MenuNodeTestCase extends DrupalWebTestCase {
|
||||
$this->drupalGet('node/' . $node->nid . '/edit');
|
||||
$this->assertOptionSelected('edit-menu-weight', 17, 'Menu weight correct in edit form');
|
||||
|
||||
// Verify that the menu link title on the node edit form has the correct
|
||||
// maxlength.
|
||||
$this->assertPattern('/<input .* id="edit-menu-link-title" .* maxlength="255" .* \/>/', 'Menu link title field has correct maxlength in node edit form.');
|
||||
|
||||
// Edit the node and remove the menu link.
|
||||
$edit = array(
|
||||
'menu[enabled]' => FALSE,
|
||||
|
||||
Reference in New Issue
Block a user