function MigrateVocabularyEntityFormDisplayTest::assertEntity
Asserts various aspects of a form display entity.
@internal
Parameters
string $id: The entity ID.
string $expected_entity_type: The expected entity type to which the display settings are attached.
string $expected_bundle: The expected bundle to which the display settings are attached.
1 call to MigrateVocabularyEntityFormDisplayTest::assertEntity()
- MigrateVocabularyEntityFormDisplayTest::testVocabularyEntityFormDisplay in core/
modules/ forum/ tests/ src/ Kernel/ Migrate/ d6/ MigrateVocabularyEntityFormDisplayTest.php  - Tests the Drupal 6 vocabulary-node type association to Drupal 8 migration.
 
File
- 
              core/
modules/ forum/ tests/ src/ Kernel/ Migrate/ d6/ MigrateVocabularyEntityFormDisplayTest.php, line 70  
Class
- MigrateVocabularyEntityFormDisplayTest
 - Vocabulary entity form display migration.
 
Namespace
Drupal\Tests\forum\Kernel\Migrate\d6Code
protected function assertEntity(string $id, string $expected_entity_type, string $expected_bundle) : void {
  /** @var \Drupal\Core\Entity\Display\EntityFormDisplayInterface $entity */
  $entity = EntityFormDisplay::load($id);
  $this->assertInstanceOf(EntityFormDisplayInterface::class, $entity);
  $this->assertSame($expected_entity_type, $entity->getTargetEntityTypeId());
  $this->assertSame($expected_bundle, $entity->getTargetBundle());
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.