You are here

public function LingotekFunctionalTest::setUp in Lingotek Translation 7.4

Same name and namespace in other branches
  1. 7.7 tests/lingotek.base.test \LingotekFunctionalTest::setUp()
  2. 7.2 tests/lingotek.base.test \LingotekFunctionalTest::setUp()
  3. 7.3 tests/lingotek.base.test \LingotekFunctionalTest::setUp()
  4. 7.5 tests/lingotek.base.test \LingotekFunctionalTest::setUp()
  5. 7.6 tests/lingotek.base.test \LingotekFunctionalTest::setUp()

Does general setup for all Lingotek tests.

Overrides DrupalWebTestCase::setUp

File

tests/lingotek.base.test, line 62
Declares a parent class to be used with Lingotek automated tests.

Class

LingotekFunctionalTest
A parent class for Lingotek autoamted tests.

Code

public function setUp() {
  parent::setUp('lingotek');
  variable_set('language_content_type_page', LINGOTEK_ENABLED);
  $unprivileged_permissions = array_keys(node_permission());
  $this->unprivileged_user = $this
    ->drupalCreateUser($unprivileged_permissions);
  $privileged_permissions = array_merge($unprivileged_permissions, array_keys(lingotek_permission()));
  $this->privileged_user = $this
    ->drupalCreateUser($privileged_permissions);
  $this
    ->connectToLingotek();
}