You are here

public function LanguageHierarchyBaseTestCase::getTranslatorUser in Language Hierarchy 7

Returns a user with minimal translation rights.

Parameters

$permissions: Additional permissions for administrative user.

1 call to LanguageHierarchyBaseTestCase::getTranslatorUser()
LanguageHierarchyBaseTestCase::loginTranslatorUser in tests/language_hierarchy.test
Log in as translator user.

File

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

Class

LanguageHierarchyBaseTestCase
Base class for Language Hierarchy module tests.

Code

public function getTranslatorUser(array $permissions = array()) {
  if (!isset($this->translator_user)) {
    $this->translator_user = $this
      ->drupalCreateUser(array_merge($this->translator_user_permissions, $permissions));
  }
  return $this->translator_user;
}