ModuleHandlerDeprecatedHookUnimplementedTest.php in Drupal 8
File
core/tests/Drupal/KernelTests/Core/Extension/ModuleHandlerDeprecatedHookUnimplementedTest.php
View source
<?php
namespace Drupal\KernelTests\Core\Extension;
use Drupal\KernelTests\KernelTestBase;
class ModuleHandlerDeprecatedHookUnimplementedTest extends KernelTestBase {
public function testUnimplementedHooks() {
$unimplemented_hook_name = 'unimplemented_hook_name';
$module_handler = $this->container
->get('module_handler');
$module_handler
->invokeDeprecated('Use something else.', 'deprecation_test', $unimplemented_hook_name);
$module_handler
->invokeAllDeprecated('Use something else.', $unimplemented_hook_name);
$data = [];
$module_handler
->alterDeprecated('Alter something else.', $unimplemented_hook_name, $data);
}
}