You are here

protected function HistoryTest::setUp in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/history/tests/src/Functional/HistoryTest.php \Drupal\Tests\history\Functional\HistoryTest::setUp()

Overrides BrowserTestBase::setUp

File

core/modules/history/tests/src/Functional/HistoryTest.php, line 45

Class

HistoryTest
Tests the History endpoints.

Namespace

Drupal\Tests\history\Functional

Code

protected function setUp() : void {
  parent::setUp();
  $this
    ->drupalCreateContentType([
    'type' => 'page',
    'name' => 'Basic page',
  ]);
  $this->user = $this
    ->drupalCreateUser([
    'create page content',
    'edit own page content',
    'access content',
  ]);
  $this
    ->drupalLogin($this->user);
  $this->testNode = $this
    ->drupalCreateNode([
    'type' => 'page',
    'uid' => $this->user
      ->id(),
  ]);
}