function MigratePrivateFileTest::getFileMigrationInfo

Same name and namespace in other branches
  1. 8.9.x core/modules/file/tests/src/Kernel/Migrate/d7/MigratePrivateFileTest.php \Drupal\Tests\file\Kernel\Migrate\d7\MigratePrivateFileTest::getFileMigrationInfo()
  2. 10 core/modules/file/tests/src/Kernel/Migrate/d7/MigratePrivateFileTest.php \Drupal\Tests\file\Kernel\Migrate\d7\MigratePrivateFileTest::getFileMigrationInfo()
  3. 11.x core/modules/file/tests/src/Kernel/Migrate/d7/MigratePrivateFileTest.php \Drupal\Tests\file\Kernel\Migrate\d7\MigratePrivateFileTest::getFileMigrationInfo()

Returns information about the file to be migrated.

Return value

array Array with keys 'path', 'size', 'base_path', and 'plugin_id'.

Overrides FileMigrationSetupTrait::getFileMigrationInfo

File

core/modules/file/tests/src/Kernel/Migrate/d7/MigratePrivateFileTest.php, line 34

Class

MigratePrivateFileTest
Tests private files migration.

Namespace

Drupal\Tests\file\Kernel\Migrate\d7

Code

protected function getFileMigrationInfo() {
    return [
        'path' => 'private://sites/default/private/Babylon5.txt',
        'size' => '3',
        'base_path' => 'private://',
        'plugin_id' => 'd7_file_private',
    ];
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.