You are here

public function UserProtectViewsBulkOperationsWebTest::setUp in User protect 7

Overrides DrupalWebTestCase::setUp().

Overrides UserProtectWebTestBase::setUp

File

tests/UserProtectViewsBulkOperationsWebTest.test, line 35
Contains UserProtectViewsBulkOperationsWebTest.

Class

UserProtectViewsBulkOperationsWebTest
Tests if user bulk operations provided by Views Bulk Operations are protected.

Code

public function setUp($modules = array()) {
  $modules = array_merge(array(
    'views_bulk_operations',
    'userprotect_test',
  ), $modules);
  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,
  ));
  $this->account = $this
    ->drupalCreateUser(array(
    'administer users',
    'administer permissions',
  ));
  $this
    ->drupalLogin($this->account);
}