diff --git a/core/modules/shortcut/lib/Drupal/shortcut/Tests/ShortcutLinksTest.php b/core/modules/shortcut/lib/Drupal/shortcut/Tests/ShortcutLinksTest.php index 6bc3a2c..59894be 100644 --- a/core/modules/shortcut/lib/Drupal/shortcut/Tests/ShortcutLinksTest.php +++ b/core/modules/shortcut/lib/Drupal/shortcut/Tests/ShortcutLinksTest.php @@ -12,6 +12,13 @@ */ class ShortcutLinksTest extends ShortcutTestBase { + /** + * Modules to enable. + * + * @var array + */ + public static $modules = array('views'); + public static function getInfo() { return array( 'name' => 'Shortcut link functionality', @@ -108,6 +115,19 @@ function testShortcutLinkChangePath() { } /** + * Tests that changing the route of a shortcut link works. + */ + function testShortcutLinkChangeRoute() { + $this->drupalLogin($this->root_user); + $this->drupalGet('admin/content'); + $this->assertResponse(200); + // Disable the view. + entity_load('view', 'content')->disable()->save(); + $this->drupalGet('admin/content'); + $this->assertResponse(200); + } + + /** * Tests deleting a shortcut link. */ function testShortcutLinkDelete() { @@ -152,4 +172,5 @@ function testNoShortcutLink() { $this->drupalGet('admin/content/node'); $this->assertRaw('add-shortcut', 'Add to shortcuts link was shown on a page the user does have access to.'); } + }