You are here

public function AccessGrantInterfaceTest::setUp in Access Control Kit 7

Overrides DrupalWebTestCase::setUp().

Overrides DrupalWebTestCase::setUp

File

./access.test, line 642
Tests for the access control kit module.

Class

AccessGrantInterfaceTest
Tests the access grant interface.

Code

public function setUp() {

  // Enable the access control kit module.
  parent::setUp(array(
    'access',
  ));

  // Create and log in our admin user.
  $this->adminUser = $this
    ->drupalCreateUser(array(
    'administer access grants',
  ));
  $this
    ->drupalLogin($this->adminUser);

  // Create a user role for use in an access scheme.
  $rid = $this
    ->drupalCreateRole(array(
    'access content',
  ));
  $this->ackRole = user_role_load($rid);

  // Create a user account for use in access grants.
  $this->ackUser = $this
    ->drupalCreateUser(array(
    'access content',
  ));
}