You are here

protected function FacebookWallBaseTestCase::loginUser1 in Facebook Wall 7

Log in as user 1.

1 call to FacebookWallBaseTestCase::loginUser1()
FacebookWallBaseTestCase::setUp in tests/FacebookWallBaseTestCase.test
Sets up a Drupal site for running functional and integration tests.

File

tests/FacebookWallBaseTestCase.test, line 45
Test admin functionality of Facebook Wall.

Class

FacebookWallBaseTestCase
Base test class for others to expand upon

Code

protected function loginUser1() {
  $password = user_password();

  // Reset the user 1 password.
  $account = user_load(1);
  $edit = array(
    'pass' => $password,
  );
  $account = user_save($account, $edit);
  $account->pass_raw = $password;

  // Log in as user 1.
  $this
    ->drupalLogin($account);
}