function MigrateBlockNoBlockContentTest::setUp
Same name in other branches
- 10 core/modules/block/tests/src/Kernel/Migrate/d7/MigrateBlockNoBlockContentTest.php \Drupal\Tests\block\Kernel\Migrate\d7\MigrateBlockNoBlockContentTest::setUp()
Overrides MigrateDrupal7TestBase::setUp
File
-
core/
modules/ block/ tests/ src/ Kernel/ Migrate/ d7/ MigrateBlockNoBlockContentTest.php, line 36
Class
- MigrateBlockNoBlockContentTest
- Tests the migration of blocks without Block Content installed.
Namespace
Drupal\Tests\block\Kernel\Migrate\d7Code
protected function setUp() : void {
parent::setUp();
// Install the themes used for this test.
$this->container
->get('theme_installer')
->install([
'olivero',
'claro',
]);
$this->installConfig(static::$modules);
$this->installEntitySchema('path_alias');
// Set Olivero and Claro as the default public and admin theme.
$config = $this->config('system.theme');
$config->set('default', 'olivero');
$config->set('admin', 'claro');
$config->save();
$this->executeMigrations([
'd7_filter_format',
'd7_user_role',
'd7_block',
]);
$blockRebuild = new BlockHooks();
$blockRebuild->rebuild();
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.