function SystemAdminTestCase::setUp

Overrides DrupalWebTestCase::setUp

File

modules/system/system.test, line 2827

Class

SystemAdminTestCase
Tests administrative overview pages.

Code

function setUp() {
    // testAdminPages() requires Locale module.
    parent::setUp(array(
        'locale',
    ));
    // Create an administrator with all permissions, as well as a regular user
    // who can only access administration pages and perform some Locale module
    // administrative tasks, but not all of them.
    $this->admin_user = $this->drupalCreateUser(array_keys(module_invoke_all('permission')));
    $this->web_user = $this->drupalCreateUser(array(
        'access administration pages',
        'translate interface',
    ));
    $this->drupalLogin($this->admin_user);
}

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