function drupal_static_reset

Resets one or all centrally stored static variable(s).


$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.

111 calls to drupal_static_reset()
block_page_build in drupal/modules/block/block.module
Implements hook_page_build().
book_node_delete in drupal/modules/book/book.module
Implements hook_node_delete().
BootstrapGetFilenameTestCase::testDrupalGetFilename in drupal/modules/simpletest/tests/bootstrap.test
Test that drupal_get_filename() works correctly when the file is not found in the database.
BootstrapIPAddressTestCase::setUp in drupal/modules/simpletest/tests/bootstrap.test
Sets up a Drupal site for running functional and integration tests.
BootstrapIPAddressTestCase::tearDown in drupal/modules/simpletest/tests/bootstrap.test
Delete created files and temporary files directory, delete the tables created by setUp(), and reset the database prefix.

... See full list


drupal/includes/, line 3707
Functions that need to be loaded on every Drupal request.


function drupal_static_reset($name = NULL) {
  drupal_static($name, NULL, TRUE);