function TrackerTest::setUp

Same name in other branches
  1. 9 core/modules/tracker/tests/src/Functional/TrackerTest.php \Drupal\Tests\tracker\Functional\TrackerTest::setUp()
  2. 8.9.x core/modules/tracker/tests/src/Functional/TrackerTest.php \Drupal\Tests\tracker\Functional\TrackerTest::setUp()
  3. 10 core/modules/tracker/tests/src/Functional/TrackerTest.php \Drupal\Tests\tracker\Functional\TrackerTest::setUp()
  4. 11.x core/modules/tracker/tests/src/Functional/TrackerTest.php \Drupal\Tests\tracker\Functional\TrackerTest::setUp()

Overrides DrupalWebTestCase::setUp

File

modules/tracker/tracker.test, line 35

Class

TrackerTest
Defines a base class for testing tracker.module.

Code

function setUp() {
    parent::setUp('comment', 'tracker');
    $permissions = array(
        'access comments',
        'create page content',
        'post comments',
        'skip comment approval',
    );
    $this->user = $this->drupalCreateUser($permissions);
    $this->other_user = $this->drupalCreateUser($permissions);
    // Make node preview optional.
    variable_set('comment_preview_page', 0);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.