function OliveroTest::testConfigSchema
Same name in other branches
- 9 core/tests/Drupal/FunctionalTests/Theme/OliveroTest.php \Drupal\FunctionalTests\Theme\OliveroTest::testConfigSchema()
- 11.x core/tests/Drupal/FunctionalTests/Theme/OliveroTest.php \Drupal\FunctionalTests\Theme\OliveroTest::testConfigSchema()
Test Olivero's configuration schema.
File
-
core/
tests/ Drupal/ FunctionalTests/ Theme/ OliveroTest.php, line 52
Class
- OliveroTest
- Tests the Olivero theme.
Namespace
Drupal\FunctionalTests\ThemeCode
public function testConfigSchema() : void {
// Required configuration.
$this->drupalGet('');
$this->assertSession()
->statusCodeEquals(200);
$this->assertSession()
->elementExists('css', '#block-olivero-content');
$this->assertSession()
->elementNotExists('css', '#block-olivero-search-form-wide');
// Optional configuration.
\Drupal::service('module_installer')->install([
'search',
'image',
'help',
'node',
]);
$this->rebuildAll();
$this->drupalLogin($this->drupalCreateUser([
'search content',
]));
// Confirm search block was installed.
$this->assertSession()
->elementExists('css', '#block-olivero-search-form-wide');
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.