function FunctionalTestSetupTrait::resetAll

Same name and namespace in other branches
  1. 8.9.x core/lib/Drupal/Core/Test/FunctionalTestSetupTrait.php \Drupal\Core\Test\FunctionalTestSetupTrait::resetAll()
  2. 10 core/lib/Drupal/Core/Test/FunctionalTestSetupTrait.php \Drupal\Core\Test\FunctionalTestSetupTrait::resetAll()
  3. 11.x core/lib/Drupal/Core/Test/FunctionalTestSetupTrait.php \Drupal\Core\Test\FunctionalTestSetupTrait::resetAll()

Resets all data structures after having enabled new modules.

This method is called by FunctionalTestSetupTrait::rebuildAll() after enabling the requested modules. It must be called again when additional modules are enabled later.

See also

\Drupal\Core\Test\FunctionalTestSetupTrait::rebuildAll()

\Drupal\Tests\BrowserTestBase::installDrupal()

68 calls to FunctionalTestSetupTrait::resetAll()
AggregatorAdminTest::testSettingsPage in core/modules/aggregator/tests/src/Functional/AggregatorAdminTest.php
Tests the settings form to ensure the correct default values are used.
CKEditorAdminTest::testExistingFormat in core/modules/ckeditor/tests/src/Functional/CKEditorAdminTest.php
Tests configuring a text editor for an existing text format.
CKEditorIntegrationTest::testOffCanvasStyles in core/modules/ckeditor/tests/src/FunctionalJavascript/CKEditorIntegrationTest.php
Tests if CKEditor is properly styled inside an off-canvas dialog.
CKEditorLoadingTest::testLoading in core/modules/ckeditor/tests/src/Functional/CKEditorLoadingTest.php
Tests loading of CKEditor CSS, JS and JS settings.
ClassLoaderTest::testAutoloadFromModuleFile in core/modules/system/tests/src/Functional/Module/ClassLoaderTest.php
Tests that .module files can use class constants in main section.

... See full list

File

core/lib/Drupal/Core/Test/FunctionalTestSetupTrait.php, line 225

Class

FunctionalTestSetupTrait
Defines a trait for shared functional test setup functionality.

Namespace

Drupal\Core\Test

Code

protected function resetAll() {
    // Clear all database and static caches and rebuild data structures.
    drupal_flush_all_caches();
    $this->container = \Drupal::getContainer();
    // Reset static variables and reload permissions.
    $this->refreshVariables();
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.