public function EntityFinderTest::testFindEntitiesByUuid in Feeds 8.3
@covers ::findEntities
File
- tests/
src/ Unit/ EntityFinderTest.php, line 138
Class
- EntityFinderTest
- @coversDefaultClass \Drupal\feeds\EntityFinder @group feeds
Namespace
Drupal\Tests\feeds\UnitCode
public function testFindEntitiesByUuid() {
$entity = $this
->prophesize(ContentEntityInterface::class);
$entity
->id()
->willReturn(17);
$this->entityRepository
->loadEntityByUuid('foo', '31835cb0-7302-403b-92ab-c228547d13fc')
->willReturn($entity);
$entity_ids = $this
->createEntityFinderInstance()
->findEntities('foo', 'uuid', '31835cb0-7302-403b-92ab-c228547d13fc');
$this
->assertEquals([
17,
], $entity_ids);
}