function drupal_static_reset in Zircon Profile 8.0
Same name and namespace in other branches
- 8 core/includes/bootstrap.inc \drupal_static_reset()
Resets one or all centrally stored static variable(s).
Parameters
$name: Name of the static variable to reset. Omit to reset all variables. Resetting all variables should only be used, for example, for running unit tests with a clean environment.
43 calls to drupal_static_reset()
- BrowserTestBase::prepareEnvironment in core/
modules/ simpletest/ src/ BrowserTestBase.php - Prepares the current environment for running the test.
- BrowserTestBase::refreshVariables in core/
modules/ simpletest/ src/ BrowserTestBase.php - Refreshes in-memory configuration and state information.
- ContentTranslationOperationsTest::setUp in core/
modules/ content_translation/ src/ Tests/ ContentTranslationOperationsTest.php - Sets up a Drupal site for running functional and integration tests.
- ContentTranslationTestBase::enableTranslation in core/
modules/ content_translation/ src/ Tests/ ContentTranslationTestBase.php - Enables translation for the current entity type and bundle.
- drupal_flush_all_caches in core/
includes/ common.inc - Flushes all persistent caches, resets all variables, and rebuilds all data structures.
1 string reference to 'drupal_static_reset'
- KernelTestBase::tearDown in core/
tests/ Drupal/ KernelTests/ KernelTestBase.php
File
- core/
includes/ bootstrap.inc, line 908 - Functions that need to be loaded on every Drupal request.
Code
function drupal_static_reset($name = NULL) {
drupal_static($name, NULL, TRUE);
}