function MigrateDrupalTestBase::setUp

Same name in other branches
  1. 9 core/modules/migrate_drupal/tests/src/Kernel/MigrateDrupalTestBase.php \Drupal\Tests\migrate_drupal\Kernel\MigrateDrupalTestBase::setUp()
  2. 9 core/modules/tracker/tests/src/Kernel/Migrate/d7/MigrateDrupalTestBase.php \Drupal\Tests\tracker\Kernel\Migrate\d7\MigrateDrupalTestBase::setUp()
  3. 10 core/modules/migrate_drupal/tests/src/Kernel/MigrateDrupalTestBase.php \Drupal\Tests\migrate_drupal\Kernel\MigrateDrupalTestBase::setUp()
  4. 10 core/modules/tracker/tests/src/Kernel/Migrate/d7/MigrateDrupalTestBase.php \Drupal\Tests\tracker\Kernel\Migrate\d7\MigrateDrupalTestBase::setUp()
  5. 11.x core/modules/migrate_drupal/tests/src/Kernel/MigrateDrupalTestBase.php \Drupal\Tests\migrate_drupal\Kernel\MigrateDrupalTestBase::setUp()
  6. 11.x core/modules/tracker/tests/src/Kernel/Migrate/d7/MigrateDrupalTestBase.php \Drupal\Tests\tracker\Kernel\Migrate\d7\MigrateDrupalTestBase::setUp()

Overrides MigrateTestBase::setUp

13 calls to MigrateDrupalTestBase::setUp()
DestinationCategoryTest::setUp in core/modules/migrate_drupal/tests/src/Kernel/Plugin/migrate/DestinationCategoryTest.php
MigrateAggregatorStubTest::setUp in core/modules/aggregator/tests/src/Kernel/Migrate/MigrateAggregatorStubTest.php
MigrateBlockContentStubTest::setUp in core/modules/block_content/tests/src/Kernel/Migrate/MigrateBlockContentStubTest.php
MigrateCommentStubTest::setUp in core/modules/comment/tests/src/Kernel/Migrate/MigrateCommentStubTest.php
MigrateDrupal6TestBase::setUp in core/modules/migrate_drupal/tests/src/Kernel/d6/MigrateDrupal6TestBase.php

... See full list

13 methods override MigrateDrupalTestBase::setUp()
DestinationCategoryTest::setUp in core/modules/migrate_drupal/tests/src/Kernel/Plugin/migrate/DestinationCategoryTest.php
MigrateAggregatorStubTest::setUp in core/modules/aggregator/tests/src/Kernel/Migrate/MigrateAggregatorStubTest.php
MigrateBlockContentStubTest::setUp in core/modules/block_content/tests/src/Kernel/Migrate/MigrateBlockContentStubTest.php
MigrateCommentStubTest::setUp in core/modules/comment/tests/src/Kernel/Migrate/MigrateCommentStubTest.php
MigrateDrupal6TestBase::setUp in core/modules/migrate_drupal/tests/src/Kernel/d6/MigrateDrupal6TestBase.php

... See full list

File

core/modules/migrate_drupal/tests/src/Kernel/MigrateDrupalTestBase.php, line 30

Class

MigrateDrupalTestBase
Base class for Drupal migration tests.

Namespace

Drupal\Tests\migrate_drupal\Kernel

Code

protected function setUp() {
    parent::setUp();
    $module_handler = \Drupal::moduleHandler();
    if ($module_handler->moduleExists('node')) {
        $this->installEntitySchema('node');
    }
    if ($module_handler->moduleExists('comment')) {
        $this->installEntitySchema('comment');
    }
    if ($module_handler->moduleExists('taxonomy')) {
        $this->installEntitySchema('taxonomy_term');
    }
    if ($module_handler->moduleExists('user')) {
        $this->installEntitySchema('user');
    }
    $this->installConfig([
        'migrate_drupal',
        'system',
    ]);
}

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