function UpdatesWith7xTest::setUp

Same name in other branches
  1. 9 core/modules/system/tests/src/Functional/UpdateSystem/UpdatesWith7xTest.php \Drupal\Tests\system\Functional\UpdateSystem\UpdatesWith7xTest::setUp()
  2. 8.9.x core/modules/system/tests/src/Functional/UpdateSystem/UpdatesWith7xTest.php \Drupal\Tests\system\Functional\UpdateSystem\UpdatesWith7xTest::setUp()
  3. 11.x core/modules/system/tests/src/Functional/UpdateSystem/UpdatesWith7xTest.php \Drupal\Tests\system\Functional\UpdateSystem\UpdatesWith7xTest::setUp()

Overrides BrowserTestBase::setUp

File

core/modules/system/tests/src/Functional/UpdateSystem/UpdatesWith7xTest.php, line 45

Class

UpdatesWith7xTest
Tests the minimum schema version when only 7.x update hooks are retained.

Namespace

Drupal\Tests\system\Functional\UpdateSystem

Code

protected function setUp() : void {
    parent::setUp();
    require_once $this->root . '/core/includes/update.inc';
    $this->updateUrl = Url::fromRoute('system.db_update')->setAbsolute()
        ->toString();
    $this->updateUser = $this->drupalCreateUser([
        'administer software updates',
    ]);
}

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