You are here

function ElementsTableSelectTest::testEmptyText in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 core/modules/system/src/Tests/Form/ElementsTableSelectTest.php \Drupal\system\Tests\Form\ElementsTableSelectTest::testEmptyText()

Test the display of the #empty text when #options is an empty array.

File

core/modules/system/src/Tests/Form/ElementsTableSelectTest.php, line 90
Contains \Drupal\system\Tests\Form\ElementsTableSelectTest.

Class

ElementsTableSelectTest
Tests the tableselect form element for expected behavior.

Namespace

Drupal\system\Tests\Form

Code

function testEmptyText() {
  $this
    ->drupalGet('form_test/tableselect/empty-text');
  $this
    ->assertText(t('Empty text.'), 'Empty text should be displayed.');
}