function LanguageSwitchingTest::setUp

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

Overrides BrowserTestBase::setUp

File

core/modules/language/tests/src/Functional/LanguageSwitchingTest.php, line 46

Class

LanguageSwitchingTest
Functional tests for the language switching feature.

Namespace

Drupal\Tests\language\Functional

Code

protected function setUp() : void {
    parent::setUp();
    // Create and log in user.
    $admin_user = $this->drupalCreateUser([
        'administer blocks',
        'administer languages',
        'administer site configuration',
        'access administration pages',
        'access content',
    ]);
    $this->drupalLogin($admin_user);
}

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