class LanguageConfigurationElementTest in Drupal 10
Same name in this branch
- 10 core/modules/language/tests/src/Functional/LanguageConfigurationElementTest.php \Drupal\Tests\language\Functional\LanguageConfigurationElementTest
- 10 core/modules/language/tests/language_elements_test/src/Form/LanguageConfigurationElementTest.php \Drupal\language_elements_test\Form\LanguageConfigurationElementTest
Same name and namespace in other branches
- 8 core/modules/language/tests/language_elements_test/src/Form/LanguageConfigurationElementTest.php \Drupal\language_elements_test\Form\LanguageConfigurationElementTest
- 9 core/modules/language/tests/language_elements_test/src/Form/LanguageConfigurationElementTest.php \Drupal\language_elements_test\Form\LanguageConfigurationElementTest
A form containing a language select element.
@internal
Hierarchy
- class \Drupal\Core\Form\FormBase implements ContainerInjectionInterface, FormInterface uses DependencySerializationTrait, LoggerChannelTrait, MessengerTrait, RedirectDestinationTrait, StringTranslationTrait
- class \Drupal\language_elements_test\Form\LanguageConfigurationElementTest
Expanded class hierarchy of LanguageConfigurationElementTest
1 string reference to 'LanguageConfigurationElementTest'
- language_elements_test.routing.yml in core/
modules/ language/ tests/ language_elements_test/ language_elements_test.routing.yml - core/modules/language/tests/language_elements_test/language_elements_test.routing.yml
File
- core/
modules/ language/ tests/ language_elements_test/ src/ Form/ LanguageConfigurationElementTest.php, line 13
Namespace
Drupal\language_elements_test\FormView source
class LanguageConfigurationElementTest extends FormBase {
/**
* {@inheritdoc}
*/
public function getFormId() {
return 'language_elements_configuration_element_test';
}
/**
* {@inheritdoc}
*/
public function buildForm(array $form, FormStateInterface $form_state) {
$form['langcode'] = [
'#title' => t('Language select'),
'#type' => 'language_select',
'#default_value' => language_get_default_langcode('entity_test', 'some_bundle'),
];
return $form;
}
/**
* {@inheritdoc}
*/
public function submitForm(array &$form, FormStateInterface $form_state) {
}
}