function StableBaseThemeUpdateTest::testUpdateHookN

Tests that the Stable base theme is installed if necessary.

@expectedDeprecation There is no `base theme` property specified in the test_stable.info.yml file. The optionality of the `base theme` property is deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. All Drupal 8 themes must add `base theme: stable` to their *.info.yml file for them to continue to work as-is in future versions of Drupal. Drupal 9 requires the `base theme` property to be specified. See https://www.drupal.org/node/3066038

File

core/modules/system/tests/src/Functional/Update/StableBaseThemeUpdateTest.php, line 72

Class

StableBaseThemeUpdateTest
Tests the upgrade path for introducing the Stable base theme.

Namespace

Drupal\Tests\system\Functional\Update

Code

public function testUpdateHookN() {
    $this->assertTrue($this->themeHandler
        ->themeExists('test_stable'));
    $this->assertFalse($this->themeHandler
        ->themeExists('stable'));
    $this->runUpdates();
    // Refresh the theme handler now that Stable has been installed.
    $this->themeHandler
        ->refreshInfo();
    $this->assertTrue($this->themeHandler
        ->themeExists('stable'));
}

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