diff --git a/tests/src/Kernel/Plugin/migrate/destination/EntityReferenceRevisionsDestinationTest.php b/tests/src/Kernel/Plugin/migrate/destination/EntityReferenceRevisionsDestinationTest.php index c7768d4..02e02ec 100644 --- a/tests/src/Kernel/Plugin/migrate/destination/EntityReferenceRevisionsDestinationTest.php +++ b/tests/src/Kernel/Plugin/migrate/destination/EntityReferenceRevisionsDestinationTest.php @@ -252,17 +252,17 @@ public function testDestinationFieldMapping(array $datas) { $storage = $this->readAttribute($migration->getDestinationPlugin(), 'storage'); $migrationExecutable->import(); foreach ($data['expected'] as $expected) { - $entity = $storage->load($expected['id']); + $entity = $storage->loadRevision($expected['id']); $properties = array_diff_key($expected, array_flip(['id'])); foreach ($properties as $property => $value) { if (is_array($value)) { foreach ($value as $delta => $text) { - $this->assertNotEmpty($entity->{$property}[$delta]->entity, "Entity property $property with $delta is not empty"); + $this->assertNotEmpty($entity->{$property}[$delta]->entity, "Entity property $property with $delta is empty"); $this->assertEquals($text, $entity->{$property}[$delta]->entity->label()); } } else { - $this->assertNotEmpty($entity, $expected[$property] .' is not empty'); + $this->assertNotEmpty($entity, 'Entity with label ' . $expected[$property] .' is empty'); $this->assertEquals($expected[$property], $entity->label()); } }