3 namespace Drupal\plugin_test\Plugin\plugin_test\mock_block;
5 use Drupal\Core\Plugin\ContextAwarePluginBase;
8 * Implementation of a user name block plugin used by Plugin API context test.
10 * @see \Drupal\plugin_test\Plugin\MockBlockManager
12 class MockUserNameBlock extends ContextAwarePluginBase {
14 public function getTitle() {
15 $user = $this->getContextValue('user');
16 return $user->label();