You are here

public static function Drupal::unsetContainer in Drupal 10

Same name and namespace in other branches
  1. 8 core/lib/Drupal.php \Drupal::unsetContainer()
  2. 9 core/lib/Drupal.php \Drupal::unsetContainer()

Unsets the global container.

4 calls to Drupal::unsetContainer()
FunctionalTestSetupTrait::getDatabaseTypes in core/lib/Drupal/Core/Test/FunctionalTestSetupTrait.php
Returns all supported database driver installer objects.
KernelTestBase::bootEnvironment in core/tests/Drupal/KernelTests/KernelTestBase.php
Bootstraps a basic test environment.
KernelTestBase::tearDown in core/tests/Drupal/KernelTests/KernelTestBase.php
UnitTestCase::setUp in core/tests/Drupal/Tests/UnitTestCase.php

File

core/lib/Drupal.php, line 146

Class

Drupal
Static Service Container wrapper.

Code

public static function unsetContainer() {
  static::$container = NULL;
}