You are here

public function EntityFinderTest::setUp in Feeds 8.3

Overrides FeedsUnitTestCase::setUp

File

tests/src/Unit/EntityFinderTest.php, line 43

Class

EntityFinderTest
@coversDefaultClass \Drupal\feeds\EntityFinder @group feeds

Namespace

Drupal\Tests\feeds\Unit

Code

public function setUp() {
  parent::setUp();

  // Entity type manager.
  $this->entityTypeManager = $this
    ->prophesize(EntityTypeManagerInterface::class);

  // Entity storage (needed for entity queries).
  $this->entityStorage = $this
    ->prophesize(EntityStorageInterface::class);
  $this->entityTypeManager
    ->getStorage('foo')
    ->willReturn($this->entityStorage);

  // Entity repository.
  $this->entityRepository = $this
    ->prophesize(EntityRepositoryInterface::class);
}