function BrowserTestBase::getSession

Same name and namespace in other branches
  1. 11.x core/tests/Drupal/Tests/BrowserTestBase.php \Drupal\Tests\BrowserTestBase::getSession()
  2. 10 core/tests/Drupal/Tests/BrowserTestBase.php \Drupal\Tests\BrowserTestBase::getSession()
  3. 9 core/tests/Drupal/Tests/BrowserTestBase.php \Drupal\Tests\BrowserTestBase::getSession()
  4. 8.9.x core/tests/Drupal/Tests/BrowserTestBase.php \Drupal\Tests\BrowserTestBase::getSession()

Returns Mink session.

Parameters

string $name: (optional) Name of the session. Defaults to the active session.

Return value

\Behat\Mink\Session The active Mink session object.

24 calls to BrowserTestBase::getSession()
BlockFilterTest::testBlockFilter in core/modules/layout_builder/tests/src/FunctionalJavascript/BlockFilterTest.php
Tests block filter.
CKEditor5FragmentLinkTest::testFragmentLink in core/modules/ckeditor5/tests/src/FunctionalJavascript/CKEditor5FragmentLinkTest.php
Tests if the fragment link to a textarea works with CKEditor 5 enabled.
ContentPreviewToggleTest::assertOrderInPage in core/modules/layout_builder/tests/src/FunctionalJavascript/ContentPreviewToggleTest.php
Asserts that blocks in a given order in the page.
EntityLinkSuggestionsTest::testStandardLink in core/modules/ckeditor5/tests/src/FunctionalJavascript/EntityLinkSuggestionsTest.php
Test the entity link suggestions.
EntityReferenceWidgetTest::testWidget in core/modules/media_library/tests/src/FunctionalJavascript/EntityReferenceWidgetTest.php
Tests that the Media library's widget works as expected.

... See full list

File

core/tests/Drupal/Tests/BrowserTestBase.php, line 473

Class

BrowserTestBase
Provides a test case for functional Drupal tests.

Namespace

Drupal\Tests

Code

public function getSession($name = NULL) {
  return $this->mink
    ->getSession($name);
}

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