You are here

public function GcMigrateTestBase::setUp in GatherContent 8.5

Overrides MigrateTestBase::setUp

File

tests/src/Kernel/GcMigrateTestBase.php, line 27

Class

GcMigrateTestBase
Base class for import kernel tests.

Namespace

Drupal\Tests\gathercontent\Kernel

Code

public function setUp() {
  parent::setUp();
  $this
    ->installSchema('node', 'node_access');
  $this
    ->installEntitySchema('node');
  $this
    ->installEntitySchema('file');
  $this
    ->installSchema('file', [
    'file_usage',
  ]);
  $this
    ->installEntitySchema('taxonomy_term');
  $this
    ->installEntitySchema('paragraph');
  $this
    ->installEntitySchema('user');
  $this
    ->installEntitySchema('menu_link_content');
  $this
    ->installConfig([
    'gathercontent_test',
  ]);
  $this
    ->installSchema('system', [
    'key_value_expire',
  ]);
  MockData::$drupalRoot = $this
    ->getDrupalRoot();

  /** @var \Drupal\taxonomy\Entity\Term[] $terms */
  $terms = MockData::createTaxonomyTerms();
  foreach ($terms as $term) {
    $term
      ->save();
  }
}