class MigrateDblogConfigsTest

Same name in this branch
  1. 9 core/modules/dblog/tests/src/Kernel/Migrate/d7/MigrateDblogConfigsTest.php \Drupal\Tests\dblog\Kernel\Migrate\d7\MigrateDblogConfigsTest
Same name and namespace in other branches
  1. 10 core/modules/dblog/tests/src/Kernel/Migrate/d6/MigrateDblogConfigsTest.php \Drupal\Tests\dblog\Kernel\Migrate\d6\MigrateDblogConfigsTest
  2. 10 core/modules/dblog/tests/src/Kernel/Migrate/d7/MigrateDblogConfigsTest.php \Drupal\Tests\dblog\Kernel\Migrate\d7\MigrateDblogConfigsTest
  3. 11.x core/modules/dblog/tests/src/Kernel/Migrate/d6/MigrateDblogConfigsTest.php \Drupal\Tests\dblog\Kernel\Migrate\d6\MigrateDblogConfigsTest
  4. 11.x core/modules/dblog/tests/src/Kernel/Migrate/d7/MigrateDblogConfigsTest.php \Drupal\Tests\dblog\Kernel\Migrate\d7\MigrateDblogConfigsTest
  5. 8.9.x core/modules/dblog/tests/src/Kernel/Migrate/d6/MigrateDblogConfigsTest.php \Drupal\Tests\dblog\Kernel\Migrate\d6\MigrateDblogConfigsTest
  6. 8.9.x core/modules/dblog/tests/src/Kernel/Migrate/d7/MigrateDblogConfigsTest.php \Drupal\Tests\dblog\Kernel\Migrate\d7\MigrateDblogConfigsTest

Upgrade variables to dblog.settings.yml.

@group migrate_drupal_6

Hierarchy

Expanded class hierarchy of MigrateDblogConfigsTest

File

core/modules/dblog/tests/src/Kernel/Migrate/d6/MigrateDblogConfigsTest.php, line 13

Namespace

Drupal\Tests\dblog\Kernel\Migrate\d6
View source
class MigrateDblogConfigsTest extends MigrateDrupal6TestBase {
  use SchemaCheckTestTrait;
  
  /**
   * {@inheritdoc}
   */
  protected static $modules = [
    'dblog',
  ];
  
  /**
   * {@inheritdoc}
   */
  protected function setUp() : void {
    parent::setUp();
    // Enable dblog in the source database so that requirements are met.
    $this->sourceDatabase
      ->update('system')
      ->condition('name', 'dblog')
      ->fields([
      'status' => '1',
    ])
      ->execute();
    $this->executeMigration('d6_dblog_settings');
  }
  
  /**
   * Tests migration of dblog variables to dblog.settings.yml.
   */
  public function testDblogSettings() {
    $config = $this->config('dblog.settings');
    $this->assertSame(10000, $config->get('row_limit'));
    $this->assertConfigSchema(\Drupal::service('config.typed'), 'dblog.settings', $config->get());
  }

}

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