function CommentDisplayConfigurableTest::setUp

Same name in other branches
  1. 9 core/modules/comment/tests/src/Functional/CommentDisplayConfigurableTest.php \Drupal\Tests\comment\Functional\CommentDisplayConfigurableTest::setUp()
  2. 10 core/modules/comment/tests/src/Functional/CommentDisplayConfigurableTest.php \Drupal\Tests\comment\Functional\CommentDisplayConfigurableTest::setUp()

Overrides CommentTestBase::setUp

File

core/modules/comment/tests/src/Functional/CommentDisplayConfigurableTest.php, line 28

Class

CommentDisplayConfigurableTest
Tests making comment base fields' displays configurable.

Namespace

Drupal\Tests\comment\Functional

Code

protected function setUp() : void {
    parent::setUp();
    // Allow anonymous users to see comments.
    user_role_grant_permissions(RoleInterface::ANONYMOUS_ID, [
        'access comments',
        'access content',
    ]);
}

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