class StubThemeHandler in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/tests/Drupal/Tests/Core/Extension/ThemeHandlerTest.php \Drupal\Tests\Core\Extension\StubThemeHandler
Extends the default theme handler to mock some drupal_ methods.
Hierarchy
- class \Drupal\Core\Extension\ThemeHandler implements ThemeHandlerInterface
- class \Drupal\Tests\Core\Extension\StubThemeHandler
Expanded class hierarchy of StubThemeHandler
File
- core/
tests/ Drupal/ Tests/ Core/ Extension/ ThemeHandlerTest.php, line 297 - Contains \Drupal\Tests\Core\Extension\ThemeHandlerTest.
Namespace
Drupal\Tests\Core\ExtensionView source
class StubThemeHandler extends ThemeHandler {
/**
* Whether the CSS cache was cleared.
*
* @var bool
*/
protected $clearedCssCache;
/**
* Whether the registry should be rebuilt.
*
* @var bool
*/
protected $registryRebuild;
/**
* A list of themes keyed by name.
*
* @var array
*/
protected $systemList;
/**
* {@inheritdoc}
*/
protected function clearCssCache() {
$this->clearedCssCache = TRUE;
}
/**
* {@inheritdoc}
*/
protected function themeRegistryRebuild() {
$this->registryRebuild = TRUE;
}
/**
* {@inheritdoc}
*/
protected function systemThemeList() {
return $this->systemList;
}
/**
* {@inheritdoc}
*/
protected function systemListReset() {
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
StubThemeHandler:: |
protected | property | Whether the CSS cache was cleared. | |
StubThemeHandler:: |
protected | property | Whether the registry should be rebuilt. | |
StubThemeHandler:: |
protected | property | A list of themes keyed by name. | |
StubThemeHandler:: |
protected | function | ||
StubThemeHandler:: |
protected | function |
Wraps system_list_reset(). Overrides ThemeHandler:: |
|
StubThemeHandler:: |
protected | function |
Wraps system_list(). Overrides ThemeHandler:: |
|
StubThemeHandler:: |
protected | function | ||
ThemeHandler:: |
protected | property | The config factory to get the installed themes. | |
ThemeHandler:: |
protected | property | The config installer to install configuration. | |
ThemeHandler:: |
protected | property | The config manager used to uninstall a theme. | |
ThemeHandler:: |
protected | property | The CSS asset collection optimizer service. | |
ThemeHandler:: |
protected | property | Contains the features enabled for themes by default. | |
ThemeHandler:: |
protected | property | An extension discovery instance. | |
ThemeHandler:: |
protected | property | The info parser to parse the theme.info.yml files. | |
ThemeHandler:: |
protected | property | A list of all currently available themes. | |
ThemeHandler:: |
protected | property | A logger instance. | |
ThemeHandler:: |
protected | property | The module handler to fire themes_installed/themes_uninstalled hooks. | |
ThemeHandler:: |
protected | property | The app root. | |
ThemeHandler:: |
protected | property | The route builder to rebuild the routes if a theme is installed. | |
ThemeHandler:: |
protected | property | The state backend. | |
ThemeHandler:: |
public | function |
Adds a theme extension to the internal listing. Overrides ThemeHandlerInterface:: |
|
ThemeHandler:: |
protected | function | Finds the base themes for the specific theme. | |
ThemeHandler:: |
public | function |
Finds all the base themes for the specified theme. Overrides ThemeHandlerInterface:: |
|
ThemeHandler:: |
public | function |
Returns the default theme. Overrides ThemeHandlerInterface:: |
|
ThemeHandler:: |
protected | function | Returns an extension discovery object. | |
ThemeHandler:: |
public | function |
Gets the human readable name of a given theme. Overrides ThemeHandlerInterface:: |
|
ThemeHandler:: |
public | function |
Returns a theme extension object from the currently active theme list. Overrides ThemeHandlerInterface:: |
|
ThemeHandler:: |
public | function |
Returns an array of directories for all installed themes. Overrides ThemeHandlerInterface:: |
|
ThemeHandler:: |
public | function |
Determines if a theme should be shown in the user interface. Overrides ThemeHandlerInterface:: |
|
ThemeHandler:: |
public | function |
Installs a given list of themes. Overrides ThemeHandlerInterface:: |
|
ThemeHandler:: |
public | function |
Returns a list of currently installed themes. Overrides ThemeHandlerInterface:: |
|
ThemeHandler:: |
public | function |
Scans and collects theme extension data and their engines. Overrides ThemeHandlerInterface:: |
|
ThemeHandler:: |
public | function |
Refreshes the theme info data of currently installed themes. Overrides ThemeHandlerInterface:: |
|
ThemeHandler:: |
public | function |
Resets the internal state of the theme handler. Overrides ThemeHandlerInterface:: |
|
ThemeHandler:: |
public | function |
Sets a new default theme. Overrides ThemeHandlerInterface:: |
|
ThemeHandler:: |
public | function |
Determines whether a given theme is installed. Overrides ThemeHandlerInterface:: |
|
ThemeHandler:: |
public | function |
Uninstalls a given list of themes. Overrides ThemeHandlerInterface:: |
|
ThemeHandler:: |
public | function | Constructs a new ThemeHandler. |