function ModulesListFormWebTest::testRequiredByThemeMessage
Same name in other branches
- 9 core/modules/system/tests/src/Functional/Form/ModulesListFormWebTest.php \Drupal\Tests\system\Functional\Form\ModulesListFormWebTest::testRequiredByThemeMessage()
- 8.9.x core/modules/system/tests/src/Functional/Form/ModulesListFormWebTest.php \Drupal\Tests\system\Functional\Form\ModulesListFormWebTest::testRequiredByThemeMessage()
- 11.x core/modules/system/tests/src/Functional/Form/ModulesListFormWebTest.php \Drupal\Tests\system\Functional\Form\ModulesListFormWebTest::testRequiredByThemeMessage()
Confirm that module 'Required By' descriptions include dependent themes.
File
-
core/
modules/ system/ tests/ src/ Functional/ Form/ ModulesListFormWebTest.php, line 159
Class
Namespace
Drupal\Tests\system\Functional\FormCode
public function testRequiredByThemeMessage() : void {
$this->drupalGet('admin/modules');
$module_theme_depends_on_description = $this->getSession()
->getPage()
->findAll('css', '#edit-modules-test-module-required-by-theme-enable-description .admin-requirements li:contains("Test Theme Depending on Modules (theme) (disabled)")');
// Confirm that 'Test Theme Depending on Modules' is listed as being
// required by the module 'Test Module Required by Theme'.
$this->assertCount(1, $module_theme_depends_on_description);
// Confirm that the required by message does not appear anywhere else.
$this->assertSession()
->pageTextContains('Test Theme Depending on Modules (Theme) (Disabled)');
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.