You are here

function LanguageHierarchyBaseTestCase::drupalLogin in Language Hierarchy 7

Login the given user only if she has not changed.

Overrides DrupalWebTestCase::drupalLogin

2 calls to LanguageHierarchyBaseTestCase::drupalLogin()
LanguageHierarchyBaseTestCase::loginAdminUser in tests/language_hierarchy.test
Log in as admin user.
LanguageHierarchyBaseTestCase::loginTranslatorUser in tests/language_hierarchy.test
Log in as translator user.

File

tests/language_hierarchy.test, line 207
Tests for Language Hierarchy module.

Class

LanguageHierarchyBaseTestCase
Base class for Language Hierarchy module tests.

Code

function drupalLogin(stdClass $account) {
  if (!isset($this->current_user) || $this->current_user->uid != $account->uid) {
    $this->current_user = $account;
    parent::drupalLogin($account);
  }
}