function ShortcutSetsTestCase::testShortcutSetAdd

Tests creating a shortcut set.

File

modules/shortcut/shortcut.test, line 243

Class

ShortcutSetsTestCase
Defines shortcut set test cases.

Code

function testShortcutSetAdd() {
    $new_set = $this->generateShortcutSet($this->randomName(10));
    $sets = shortcut_sets();
    $this->assertTrue(isset($sets[$new_set->set_name]), 'Successfully created a shortcut set.');
    $this->drupalGet('user/' . $this->admin_user->uid . '/shortcuts');
    $this->assertText($new_set->title, 'Generated shortcut set was listed as a choice on the user account page.');
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.