function EntityTypeTest::testGetFormClass
Same name in other branches
- 9 core/tests/Drupal/Tests/Core/Entity/EntityTypeTest.php \Drupal\Tests\Core\Entity\EntityTypeTest::testGetFormClass()
- 8.9.x core/tests/Drupal/Tests/Core/Entity/EntityTypeTest.php \Drupal\Tests\Core\Entity\EntityTypeTest::testGetFormClass()
- 10 core/tests/Drupal/Tests/Core/Entity/EntityTypeTest.php \Drupal\Tests\Core\Entity\EntityTypeTest::testGetFormClass()
Tests the getFormClass() method.
File
-
core/
tests/ Drupal/ Tests/ Core/ Entity/ EntityTypeTest.php, line 224
Class
- EntityTypeTest
- @coversDefaultClass \Drupal\Core\Entity\EntityType @group Entity
Namespace
Drupal\Tests\Core\EntityCode
public function testGetFormClass() : void {
$operation = 'default';
$entity_type = $this->setUpEntityType([
'handlers' => [
'form' => [
$operation => StubEntityHandlerBase::class,
],
],
]);
$this->assertSame(StubEntityHandlerBase::class, $entity_type->getFormClass($operation));
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.