You are here

public function UserProtectBypassWebTest::setUp in User protect 7

Overrides DrupalWebTestCase::setUp().

Overrides UserProtectWebTestBase::setUp

File

tests/UserProtectBypassWebTest.test, line 35
Contains UserProtectBypassWebTest.

Class

UserProtectBypassWebTest
Tests bypassing protection rules.

Code

public function setUp($modules = array()) {
  parent::setUp($modules);

  // Set administrator bypass defaults to no bypassing at all.
  variable_set('userprotect_administrator_bypass_defaults', array(
    'up_name' => 0,
    'up_mail' => 0,
    'up_pass' => 0,
    'up_status' => 0,
    'up_roles' => 0,
    'up_openid' => 0,
    'up_cancel' => 0,
    'up_edit' => 0,
  ));

  // Create the operating account.
  $this->account = $this
    ->drupalCreateUser(array(
    'administer users',
    'administer permissions',
  ));
}