You are here

class TestFormWithPredefinedForm in Drupal 8

Same name and namespace in other branches
  1. 9 core/tests/Drupal/Tests/Core/Form/FormBuilderTest.php \Drupal\Tests\Core\Form\TestFormWithPredefinedForm

Hierarchy

Expanded class hierarchy of TestFormWithPredefinedForm

File

core/tests/Drupal/Tests/Core/Form/FormBuilderTest.php, line 958
Contains \Drupal\Tests\Core\Form\FormBuilderTest.

Namespace

Drupal\Tests\Core\Form
View source
class TestFormWithPredefinedForm extends TestForm {

  /**
   * @var array
   */
  protected $form;
  public function setForm($form) {
    $this->form = $form;
  }
  public function buildForm(array $form, FormStateInterface $form_state) {
    return $this->form;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
TestForm::getFormId public function Returns a unique string identifying the form. Overrides FormInterface::getFormId
TestForm::submitForm public function Form submission handler. Overrides FormInterface::submitForm
TestForm::validateForm public function Form validation handler. Overrides FormInterface::validateForm
TestFormWithPredefinedForm::$form protected property
TestFormWithPredefinedForm::buildForm public function Form constructor. Overrides TestForm::buildForm
TestFormWithPredefinedForm::setForm public function