protected function EntityRevisionTest::setUp in Drupal 9
Same name in this branch
- 9 core/modules/migrate/tests/src/Unit/destination/EntityRevisionTest.php \Drupal\Tests\migrate\Unit\destination\EntityRevisionTest::setUp()
- 9 core/modules/migrate/tests/src/Kernel/Plugin/EntityRevisionTest.php \Drupal\Tests\migrate\Kernel\Plugin\EntityRevisionTest::setUp()
- 9 core/modules/migrate/tests/src/Unit/Plugin/migrate/destination/EntityRevisionTest.php \Drupal\Tests\migrate\Unit\Plugin\migrate\destination\EntityRevisionTest::setUp()
Same name and namespace in other branches
- 8 core/modules/migrate/tests/src/Unit/destination/EntityRevisionTest.php \Drupal\Tests\migrate\Unit\destination\EntityRevisionTest::setUp()
- 10 core/modules/migrate/tests/src/Unit/destination/EntityRevisionTest.php \Drupal\Tests\migrate\Unit\destination\EntityRevisionTest::setUp()
Overrides UnitTestCase::setUp
File
- core/
modules/ migrate/ tests/ src/ Unit/ destination/ EntityRevisionTest.php, line 46 - Contains \Drupal\Tests\migrate\Unit\destination\EntityRevisionTest.
Class
- EntityRevisionTest
- Tests entity revision destination.
Namespace
Drupal\Tests\migrate\Unit\destinationCode
protected function setUp() : void {
parent::setUp();
// Setup mocks to be used when creating a revision destination.
$this->migration = $this
->prophesize(MigrationInterface::class);
$this->storage = $this
->prophesize('\\Drupal\\Core\\Entity\\EntityStorageInterface');
$entity_type = $this
->prophesize(EntityTypeInterface::class);
$entity_type
->getSingularLabel()
->willReturn('crazy');
$entity_type
->getPluralLabel()
->willReturn('craziness');
$this->storage
->getEntityType()
->willReturn($entity_type
->reveal());
$this->entityFieldManager = $this
->prophesize('\\Drupal\\Core\\Entity\\EntityFieldManagerInterface');
$this->fieldTypeManager = $this
->prophesize('\\Drupal\\Core\\Field\\FieldTypePluginManagerInterface');
}