You are here

protected function CommentStatisticsTest::setUp in Multiversion 8

Overrides MultiversionFunctionalTestBase::setUp

File

tests/src/Functional/CommentStatisticsTest.php, line 39

Class

CommentStatisticsTest
Tests comment statistics.

Namespace

Drupal\Tests\multiversion\Functional

Code

protected function setUp() {
  parent::setUp();
  $this->adminUser = $this
    ->drupalCreateUser([
    'administer content types',
    'administer blocks',
    'administer comments',
    'administer comment types',
    'post comments',
    'create article content',
    'access administration pages',
    'access comments',
    'access content',
  ]);
  $this
    ->drupalLogin($this->adminUser);
  $this
    ->drupalPlaceBlock('local_tasks_block');
  $this->node = Node::create([
    'type' => 'article',
    'title' => 'New node',
    'promote' => 1,
    'uid' => $this->adminUser
      ->id(),
  ]);
  $this->node
    ->save();
}