public function EntityFileTest::setUp in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/file/src/Tests/Migrate/EntityFileTest.php \Drupal\file\Tests\Migrate\EntityFileTest::setUp()
Performs setup tasks before each individual test method is run.
Overrides KernelTestBase::setUp
File
- core/
modules/ file/ src/ Tests/ Migrate/ EntityFileTest.php, line 40 - Contains \Drupal\file\Tests\Migrate\EntityFileTest.
Class
- EntityFileTest
- Tests the entity file destination plugin.
Namespace
Drupal\file\Tests\MigrateCode
public function setUp() {
parent::setUp();
$this->destination = new TestEntityFile([]);
$this->destination->streamWrapperManager = \Drupal::getContainer()
->get('stream_wrapper_manager');
$this->destination->fileSystem = \Drupal::getContainer()
->get('file_system');
$this
->installEntitySchema('file');
file_put_contents('/tmp/test-file.jpg', '');
}