You are here

private function ForumTest::doBasicTests in Drupal 8

Same name and namespace in other branches
  1. 9 core/modules/forum/tests/src/Functional/ForumTest.php \Drupal\Tests\forum\Functional\ForumTest::doBasicTests()

Runs basic tests on the indicated user.

Parameters

\Drupal\Core\Session\AccountInterface $user: The logged in user.

bool $admin: User has 'access administration pages' privilege.

1 call to ForumTest::doBasicTests()
ForumTest::testForum in core/modules/forum/tests/src/Functional/ForumTest.php
Tests forum functionality through the admin and user interfaces.

File

core/modules/forum/tests/src/Functional/ForumTest.php, line 509

Class

ForumTest
Tests for forum.module.

Namespace

Drupal\Tests\forum\Functional

Code

private function doBasicTests($user, $admin) {

  // Log in the user.
  $this
    ->drupalLogin($user);

  // Attempt to create forum topic under a container.
  $this
    ->createForumTopic($this->forumContainer, TRUE);

  // Create forum node.
  $node = $this
    ->createForumTopic($this->forum, FALSE);

  // Verify the user has access to all the forum nodes.
  $this
    ->verifyForums($node, $admin);
}