function SearchPageOverrideTest::setUp

Same name in other branches
  1. 8.9.x core/modules/search/tests/src/Functional/SearchPageOverrideTest.php \Drupal\Tests\search\Functional\SearchPageOverrideTest::setUp()
  2. 10 core/modules/search/tests/src/Functional/SearchPageOverrideTest.php \Drupal\Tests\search\Functional\SearchPageOverrideTest::setUp()
  3. 11.x core/modules/search/tests/src/Functional/SearchPageOverrideTest.php \Drupal\Tests\search\Functional\SearchPageOverrideTest::setUp()

Overrides BrowserTestBase::setUp

File

core/modules/search/tests/src/Functional/SearchPageOverrideTest.php, line 37

Class

SearchPageOverrideTest
Tests if the result page can be overridden.

Namespace

Drupal\Tests\search\Functional

Code

protected function setUp() : void {
    parent::setUp();
    // Log in as a user that can create and search content.
    $this->searchUser = $this->drupalCreateUser([
        'search content',
        'administer search',
    ]);
    $this->drupalLogin($this->searchUser);
}

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