Issue #3313021 by Spokje: Remove obsolete \Drupal\KernelTests\KernelTestBase::prepareTemplate

merge-requests/2418/merge
Alex Pott 2022-10-03 10:13:16 +01:00
parent 79b8681f31
commit c0bc0eb3f4
No known key found for this signature in database
GPG Key ID: BDA67E7EE836E5CE
1 changed files with 0 additions and 21 deletions

View File

@ -988,27 +988,6 @@ abstract class KernelTestBase extends TestCase implements ServiceProviderInterfa
return call_user_func_array('array_merge_recursive', $modules);
}
/**
* {@inheritdoc}
*/
protected function prepareTemplate(\Text_Template $template) {
$bootstrap_globals = '';
// Fix missing bootstrap.php when $preserveGlobalState is FALSE.
// @see https://github.com/sebastianbergmann/phpunit/pull/797
$bootstrap_globals .= '$__PHPUNIT_BOOTSTRAP = ' . var_export($GLOBALS['__PHPUNIT_BOOTSTRAP'], TRUE) . ";\n";
// Avoid repetitive test namespace discoveries to improve performance.
// @see /core/tests/bootstrap.php
$bootstrap_globals .= '$namespaces = ' . var_export($GLOBALS['namespaces'], TRUE) . ";\n";
$template->setVar([
'constants' => '',
'included_files' => '',
'globals' => $bootstrap_globals,
]);
}
/**
* Prevents serializing any properties.
*