You are here

protected function TestBase::prepareDatabase in Workbench Moderation to Content Moderation 8.2

Same name in this branch
  1. 8.2 tests/src/Functional/TestBase.php \Drupal\Tests\wbm2cm\Functional\TestBase::prepareDatabase()
  2. 8.2 tests/src/Kernel/Migration/TestBase.php \Drupal\Tests\wbm2cm\Kernel\Migration\TestBase::prepareDatabase()

Overrides MigrationTestTrait::prepareDatabase

1 call to TestBase::prepareDatabase()
TestBase::setUp in tests/src/Kernel/Migration/TestBase.php

File

tests/src/Kernel/Migration/TestBase.php, line 69

Class

TestBase
Tests the save-clear-restore migration flow for a single entity type.

Namespace

Drupal\Tests\wbm2cm\Kernel\Migration

Code

protected function prepareDatabase() {

  // TODO: Put this bullshit in the source plugin configuration.
  $db = $this
    ->getDatabaseConnectionInfo();
  $db['default']['prefix']['default'] = $this
    ->getDatabasePrefix();
  Database::addConnectionInfo('migrate', 'default', $db['default']);
}