public function MigrateTermNodeRevisionTest::testTermRevisionNode in Drupal 9
Same name and namespace in other branches
- 8 core/modules/taxonomy/tests/src/Kernel/Migrate/d6/MigrateTermNodeRevisionTest.php \Drupal\Tests\taxonomy\Kernel\Migrate\d6\MigrateTermNodeRevisionTest::testTermRevisionNode()
Tests the Drupal 6 term-node revision association to Drupal 8 migration.
File
- core/
modules/ taxonomy/ tests/ src/ Kernel/ Migrate/ d6/ MigrateTermNodeRevisionTest.php, line 33
Class
- MigrateTermNodeRevisionTest
- Upgrade taxonomy term node associations.
Namespace
Drupal\Tests\taxonomy\Kernel\Migrate\d6Code
public function testTermRevisionNode() {
$node = \Drupal::entityTypeManager()
->getStorage('node')
->loadRevision(2001);
$this
->assertCount(2, $node->field_vocabulary_3_i_2_);
$this
->assertSame('4', $node->field_vocabulary_3_i_2_[0]->target_id);
$this
->assertSame('5', $node->field_vocabulary_3_i_2_[1]->target_id);
}