You are here

public function ContentEntityTestBase::setUp in Translation Management Tool 8

Overrides EntityKernelTestBase::setUp

7 calls to ContentEntityTestBase::setUp()
ContentEntityLinkTest::setUp in sources/content/tests/src/Kernel/ContentEntityLinkTest.php
ContentEntityMetatagTest::setUp in sources/content/tests/src/Kernel/ContentEntityMetatagTest.php
ContentEntityPathTest::setUp in sources/content/tests/src/Kernel/ContentEntityPathTest.php
ContentEntitySourceContentModerationTest::setUp in sources/content/tests/src/Kernel/ContentEntitySourceContentModerationTest.php
ContentEntitySourceUnitTest::setUp in sources/content/tests/src/Kernel/ContentEntitySourceUnitTest.php

... See full list

7 methods override ContentEntityTestBase::setUp()
ContentEntityLinkTest::setUp in sources/content/tests/src/Kernel/ContentEntityLinkTest.php
ContentEntityMetatagTest::setUp in sources/content/tests/src/Kernel/ContentEntityMetatagTest.php
ContentEntityPathTest::setUp in sources/content/tests/src/Kernel/ContentEntityPathTest.php
ContentEntitySourceContentModerationTest::setUp in sources/content/tests/src/Kernel/ContentEntitySourceContentModerationTest.php
ContentEntitySourceUnitTest::setUp in sources/content/tests/src/Kernel/ContentEntitySourceUnitTest.php

... See full list

File

sources/content/tests/src/Kernel/ContentEntityTestBase.php, line 34

Class

ContentEntityTestBase
Base class for content entity kernel tests.

Namespace

Drupal\Tests\tmgmt_content\Kernel

Code

public function setUp() : void {
  parent::setUp();

  // Add the languages.
  $this
    ->installConfig([
    'language',
  ]);
  ConfigurableLanguage::createFromLangcode('de')
    ->save();
  ConfigurableLanguage::createFromLangcode('cs')
    ->save();
  $this
    ->installEntitySchema('tmgmt_job');
  $this
    ->installEntitySchema('tmgmt_job_item');
  $this
    ->installEntitySchema('tmgmt_remote');
  $this
    ->installEntitySchema('tmgmt_message');
  $this
    ->installEntitySchema('entity_test_mul');
  $this->container
    ->get('content_translation.manager')
    ->setEnabled('entity_test_mul', 'entity_test_mul', TRUE);
  \Drupal::service('router.builder')
    ->rebuild();
  tmgmt_translator_auto_create(\Drupal::service('plugin.manager.tmgmt.translator')
    ->getDefinition('test_translator'));
}