You are here

protected function SessionTest::setUp in Drupal 10

Same name and namespace in other branches
  1. 8 core/tests/Drupal/FunctionalJavascriptTests/Core/Session/SessionTest.php \Drupal\FunctionalJavascriptTests\Core\Session\SessionTest::setUp()
  2. 9 core/tests/Drupal/FunctionalJavascriptTests/Core/Session/SessionTest.php \Drupal\FunctionalJavascriptTests\Core\Session\SessionTest::setUp()

Overrides BrowserTestBase::setUp

File

core/tests/Drupal/FunctionalJavascriptTests/Core/Session/SessionTest.php, line 28

Class

SessionTest
Tests that sessions don't expire.

Namespace

Drupal\FunctionalJavascriptTests\Core\Session

Code

protected function setUp() : void {
  parent::setUp();
  $account = $this
    ->drupalCreateUser();
  $this
    ->drupalLogin($account);
  $menu_link_content = MenuLinkContent::create([
    'title' => 'Link to front page',
    'menu_name' => 'tools',
    'link' => [
      'uri' => 'route:<front>',
    ],
  ]);
  $menu_link_content
    ->save();
  $this
    ->drupalPlaceBlock('system_menu_block:tools');
}