Remove all temporary database tables and directories.
function simpletest_clean_environment() {
simpletest_clean_database();
simpletest_clean_temporary_directories();
if (config('simpletest.settings')
->get('clear_results')) {
$count = simpletest_clean_results_table();
drupal_set_message(format_plural($count, 'Removed 1 test result.', 'Removed @count test results.'));
}
else {
drupal_set_message(t('Clear results is disabled and the test results table will not be cleared.'), 'warning');
}
// Detect test classes that have been added, renamed or deleted.
cache()
->delete('simpletest');
}