MigrateNodeTestBase.php in Drupal 9
File
core/modules/node/tests/src/Kernel/Migrate/d6/MigrateNodeTestBase.php
View source
<?php
namespace Drupal\Tests\node\Kernel\Migrate\d6;
use Drupal\Tests\migrate_drupal\Kernel\d6\MigrateDrupal6TestBase;
use Drupal\user\Entity\User;
abstract class MigrateNodeTestBase extends MigrateDrupal6TestBase {
protected function setUp() {
parent::setUp();
$this
->installEntitySchema('node');
$this
->installConfig([
'node',
]);
$this
->installSchema('node', [
'node_access',
]);
$this
->installSchema('system', [
'sequences',
]);
User::create([
'uid' => 1,
'name' => $this
->randomMachineName(),
'status' => 1,
])
->enforceIsNew()
->save();
$this
->migrateUsers(FALSE);
$this
->migrateFields();
$this
->executeMigration('d6_node_settings');
}
}