class FieldWidgetSettingsSummaryAlterEventTest in Hook Event Dispatcher 3.x
Same name and namespace in other branches
- 8.2 modules/field_event_dispatcher/tests/src/Unit/Field/FieldWidgetSettingsSummaryAlterEventTest.php \Drupal\Tests\field_event_dispatcher\Unit\Field\FieldWidgetSettingsSummaryAlterEventTest
Class FieldWidgetSettingsSummaryAlterEventTest.
@group field_event_dispatcher
Hierarchy
- class \Drupal\Tests\field_event_dispatcher\Unit\Field\AbstractFieldSettingsSummaryAlterEventTestCase extends \PHPUnit\Framework\TestCase
- class \Drupal\Tests\field_event_dispatcher\Unit\Field\FieldWidgetSettingsSummaryAlterEventTest
Expanded class hierarchy of FieldWidgetSettingsSummaryAlterEventTest
File
- modules/
field_event_dispatcher/ tests/ src/ Unit/ Field/ FieldWidgetSettingsSummaryAlterEventTest.php, line 14
Namespace
Drupal\Tests\field_event_dispatcher\Unit\FieldView source
class FieldWidgetSettingsSummaryAlterEventTest extends AbstractFieldSettingsSummaryAlterEventTestCase {
/**
* {@inheritdoc}
*/
protected function getProceduralHookName() : string {
return 'field_event_dispatcher_field_widget_settings_summary_alter';
}
/**
* {@inheritdoc}
*/
protected function getEventName() : string {
return HookEventDispatcherInterface::FIELD_WIDGET_SETTINGS_SUMMARY_ALTER;
}
/**
* {@inheritdoc}
*/
protected function getTestContext(BaseFieldDefinition $fieldDefinition) : array {
return [
'widget' => new StringTextfieldWidget('test_widget', [], $fieldDefinition, [], []),
'form_mode' => 'test',
];
}
}