You are here

public function AjaxFormPageCacheTest::testAjaxElementValidation in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/system/src/Tests/Ajax/AjaxFormPageCacheTest.php \Drupal\system\Tests\Ajax\AjaxFormPageCacheTest::testAjaxElementValidation()

Tests a form that uses an #ajax callback.

See also

\Drupal\system\Tests\Ajax\ElementValidationTest::testAjaxElementValidation()

File

core/modules/system/src/Tests/Ajax/AjaxFormPageCacheTest.php, line 102
Contains \Drupal\system\Tests\Ajax\AjaxFormPageCacheTest.

Class

AjaxFormPageCacheTest
Performs tests on AJAX forms in cached pages.

Namespace

Drupal\system\Tests\Ajax

Code

public function testAjaxElementValidation() {
  $edit = [
    'drivertext' => t('some dumb text'),
  ];
  $this
    ->drupalPostAjaxForm('ajax_validation_test', $edit, 'drivertext');
}