class TextareaTest
Same name in this branch
- 11.x core/tests/Drupal/Tests/Core/Render/Element/TextareaTest.php \Drupal\Tests\Core\Render\Element\TextareaTest
Same name in other branches
- 9 core/tests/Drupal/Tests/Core/Render/Element/TextareaTest.php \Drupal\Tests\Core\Render\Element\TextareaTest
- 8.9.x core/tests/Drupal/Tests/Core/Render/Element/TextareaTest.php \Drupal\Tests\Core\Render\Element\TextareaTest
- 10 core/tests/Drupal/Tests/Core/Render/Element/TextareaTest.php \Drupal\Tests\Core\Render\Element\TextareaTest
Tests the form API textarea element.
@group Form
Hierarchy
- class \Drupal\Tests\BrowserTestBase extends \PHPUnit\Framework\TestCase uses \Drupal\Core\Test\FunctionalTestSetupTrait, \Drupal\Tests\UiHelperTrait, \Drupal\Core\Test\TestSetupTrait, \Drupal\Tests\block\Traits\BlockCreationTrait, \Drupal\Tests\RandomGeneratorTrait, \Drupal\Tests\node\Traits\NodeCreationTrait, \Drupal\Tests\node\Traits\ContentTypeCreationTrait, \Drupal\Tests\ConfigTestTrait, \Drupal\Tests\TestRequirementsTrait, \Drupal\Tests\user\Traits\UserCreationTrait, \Drupal\Tests\XdebugRequestTrait, \Drupal\Tests\PhpUnitCompatibilityTrait, \Drupal\TestTools\Extension\DeprecationBridge\ExpectDeprecationTrait, \Drupal\Tests\ExtensionListTestTrait
- class \Drupal\Tests\system\Functional\Form\TextareaTest extends \Drupal\Tests\BrowserTestBase
Expanded class hierarchy of TextareaTest
File
-
core/
modules/ system/ tests/ src/ Functional/ Form/ TextareaTest.php, line 14
Namespace
Drupal\Tests\system\Functional\FormView source
class TextareaTest extends BrowserTestBase {
/**
* {@inheritdoc}
*/
protected static $modules = [
'form_test',
];
/**
* {@inheritdoc}
*/
protected $defaultTheme = 'stark';
/**
* Tests the textarea element #resizable property.
*/
public function testFormTextareaResizable() : void {
$this->drupalGet('form-test/textarea');
$this->assertNotEmpty($this->cssSelect('#edit-textarea-resizable-vertical.resize-vertical'));
$this->assertNotEmpty($this->cssSelect('#edit-textarea-resizable-horizontal.resize-horizontal'));
$this->assertNotEmpty($this->cssSelect('#edit-textarea-resizable-both.resize-both'));
$this->assertNotEmpty($this->cssSelect('#edit-textarea-resizable-none.resize-none'));
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.