function DatetimeElementFormTest::testDatetimeElement

Same name in other branches
  1. 9 core/tests/Drupal/KernelTests/Core/Datetime/DatetimeElementFormTest.php \Drupal\KernelTests\Core\Datetime\DatetimeElementFormTest::testDatetimeElement()
  2. 10 core/tests/Drupal/KernelTests/Core/Datetime/DatetimeElementFormTest.php \Drupal\KernelTests\Core\Datetime\DatetimeElementFormTest::testDatetimeElement()
  3. 11.x core/tests/Drupal/KernelTests/Core/Datetime/DatetimeElementFormTest.php \Drupal\KernelTests\Core\Datetime\DatetimeElementFormTest::testDatetimeElement()

Tests that default handlers are added even if custom are specified.

File

core/tests/Drupal/KernelTests/Core/Datetime/DatetimeElementFormTest.php, line 104

Class

DatetimeElementFormTest
Tests DatetimeElement functionality.

Namespace

Drupal\KernelTests\Core\Datetime

Code

public function testDatetimeElement() {
    $form = \Drupal::formBuilder()->getForm($this);
    $this->render($form);
    $this->assertEqual(t('Date time callback called.'), $this->flag);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.