Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. EnvironmentCleanerInterface.php

function EnvironmentCleanerInterface::cleanEnvironment

Removes all test-related database tables and directories.

This method removes fixture files and database entries from the system under test.

Parameters

bool $clear_results: (optional) Whether to clear the test results storage. Defaults to TRUE.

bool $clear_temp_directories: (optional) Whether to clear the test site directories. Defaults to TRUE.

bool $clear_database: (optional) Whether to clean up the fixture database. Defaults to TRUE.

1 method overrides EnvironmentCleanerInterface::cleanEnvironment()
EnvironmentCleaner::cleanEnvironment in core/lib/Drupal/Core/Test/EnvironmentCleaner.php
Removes all test-related database tables and directories.

File

core/lib/Drupal/Core/Test/EnvironmentCleanerInterface.php, line 32

Class

EnvironmentCleanerInterface
Defines an interface for cleaning up test results and fixtures.

Namespace

Drupal\Core\Test

Code

public function cleanEnvironment(bool $clear_results = TRUE, bool $clear_temp_directories = TRUE, bool $clear_database = TRUE) : void;

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal